WebSite X5Help Center

 
David F.
David F.
User

Date last updated in Home Page title  en

Автор: David F.
Просмотрено 552, Подписчики 2, Размещенный 0  

A simple question, but I suspect a difficult answer.

My website houses recordings of local news for the visually impaired.  Our recording engineers can easily upload new recordings using Filezilla, but we can't find a wqay to change the Title on our home page.

We have to download the index.html open it in a text editor find the "Date of Last Recording" text and manually edit it before saving and uploading index.html.

What I would like to do is to upload a text or html file with the relevant date and have that displayed in out tiltle instead of the hard coded date I set using X5.

I am happy to writ a program to upload the data in whatever form we need or can I edit the HTML of our home page to reference a text file?

This is the relevent part of the page

<div id="imContentGraphics"></div>
<main id="imContent">
<a id="imGoToCont"></a>
<div id="imPageRow_1" class="imPageRow">

</div>
<div id="imCell_1" class=""> <div id="imCellStyleGraphics_1"></div><div id="imCellStyleBorders_1"></div><div id="imCellStyleTitle_1">Latest recording 11th September 2024 </div><div id="imTextObject_01">
<div data-index="0" class="text-tab-content grid-prop current-tab " id="imTextObject_01_tab0" style="opacity: 1; ">
<div class="text-inner">
<div data-line-height="1" class="lh1 imTACenter">

Any help much apreciated

David

Размещено
12 Ответы - 2 Полезно
Daniel W.
Daniel W.
User
Лучший пользователь месяца EN

There is the “Dynamic Content” object, which allows authorized persons to make changes on a page.

----- WebSite X5 Guide -----

How to work with the Dynamic Content Object

>> https://guide.websitex5.com/en/support/solutions/articles/44000884500

-----

.

Here is an example (German text page) for the input window of the "Dynamic Content" object.

.

----- Screenshot -----

Читать больше
Размещено От Daniel W.
Daniel W.
Daniel W.
User
Лучший пользователь месяца EN

A login must be set up for the authorized person so that this person can log in and edit the text.

See my demo shop with the page on which the “Dynamic Content” object is used several times. Editing areas have been set up here for various authorized people.

My test page >> https://findelinks.de/123shop-hosteurope/dynamisches-objekt-2.php

Читать больше
Размещено От Daniel W.
David F.
David F.
User

Thanks for all that Daniel.

I wasn't aware of the Dynamic Content Object so I shall look into it carefully.

Giving others acces to the site is not a poblem because they alread upload direct with Filezilla, it is the display of the updat which is puzzling me.

I'll get back to you when I've studied it.

Thanks again

David

Читать больше
Размещено От David F.
David F.
David F.
User

Daniel

Thanks again but unfortunately Dynamic Content is only available in pro versions and I'm using EVO.

KolAsim

Thank you too for your link.  On another web site I am using something very similar to show the sites last updated time, just as small black text for my benefit.

In this case the recorded files may or may not have been recorded today which is why I want to use a file of some kind containing the date I wish to display, to inform listeners.

Ideally I want to put a reference to the “Style, Text” box in X5 so it always be there if I change anything else on the page.

If that’s not possible, I hoped to be able to edit the html that X5 produces, which looks like this:

 <div id="imCellStyleTitle_1">Latest recording 11th September 2024 </div><div id="imTextObject_01">

Replacing the text >Latest recording 11th September 2024 < with text from a file?

It seems such a simple thing, which I could do in a moment in any one of several programming languages but alas html is not one I am fluent in.

Thank you both again for your time and knowledge

David

Читать больше
Размещено От David F.
Daniel W.
Daniel W.
User
Лучший пользователь месяца EN

Here is a suggestion to display the update date via iframe code. Then the person who uploads the file via FileZilla could also upload the HTML file with the modification date.

My test page >> https://findelinks.de/123test-aufklappmenue/seite-25.html

.

----- A) Translations -----

German: ./datum-seite-123.html

English: ./date-page-123.html

---

German: Letzte Aktualisierung der Videoaufnahme am 12.09.2024

English: Last update of the video recording on September 12, 2024

----- B) Iframe code -----

<iframe src="./datum-seite-123.html" width="100%" height="25"></iframe>

----- C) Code in HTML file "datum-seite-123.html" -----

<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Titel</title>
</head>
<body>
Letzte Aktualisierung der Videoaufnahme am 12.09.2024
</body>
</html>

----- D) Inculding Iframe code -----

Читать больше
Размещено От Daniel W.
Daniel W.
Daniel W.
User
Лучший пользователь месяца EN

Here 2 changes:

1) The text in the HTML file is centered.

2) The iframe code comes in 3 variants (Text Only, Text with Background Color and Text with Background Color and Border).

My test page >> https://findelinks.de/123test-aufklappmenue/seite-25.html

.

----- Screenshot -----

----- HTML -----

<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Titel</title>
</head>
<body>
<div style="text-align: center">Letzte Aktualisierung der Videoaufnahme am 12.09.2024</div>
</body>
</html>

----- 1 -----

<iframe src="./datum-seite-123.html" width="100%" height="25"></iframe>

----- 2 -----

<div style="background: silver;"><iframe src="./datum-seite-123.html" width="100%" height="25"></iframe></div>

----- 3 -----

<div style="border: 4px solid black; background: silver;"><iframe src="./datum-seite-123.html" width="100%" height="25"></iframe></div>

-------------

Читать больше
Размещено От Daniel W.
Daniel W.
Daniel W.
User
Лучший пользователь месяца EN

I enhanced the HTML file displayed in the iframe with the font formatting in CSS format.

----

----- HTML -----

<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Titel</title>
<style>
.text_in_iframe {
font-family: Arial, sans-serif;
font-size: 16px;
font-weight: bold;
color: black;
text-align: Center;
}
</style>
</head>
<body>
<div class="text_in_iframe">Letzte Aktualisierung der Videoaufnahme am 12.09.2024</div>
</body>
</html>

Читать больше
Размещено От Daniel W.
John S.
John S.
User

You could use GoogleDoc for that.

make a document in GoogleDoc.

Make the document "public".

Use the code you can have Googe to show.

Use the code in an iframe using a html-object for that.

This is free. It can be used in any X5 version. 

Читать больше
Размещено От John S.
 ‪ KolAsim ‪ ‪
 ‪ KolAsim ‪ ‪
Moderator
David F.
... ... ...  KolAsim ... ... ...  Ideally I want to put a reference to the “Style, Text” box in X5 so it always be there if I change anything else on the page. ... ... ... 

(It > En) ... the code I posted is very simple and the date updates only when the page changes...
... for example, if you want to try it right away with a British date format (DD-MM-YYYY), simply paste this code into an HTML Code Object:
<div id="lastmodifiedK">dataK</div>
<script>
dataK = document.lastModified.split("/").join("-");
datatextK = "page updated on: " + dataK;
$("#lastmodifiedK").text(datatextK);/** - K - **/
</script>

... if you want the date in an EN-USA format (MM-DD-YYYY), let me know...

... if you already have a dedicated text field for this purpose, send me the LINK of the page, so that I can evaluate the most suitable dynamic code...

.

ciao

.
.

Читать больше
Размещено От  ‪ KolAsim ‪ ‪