Change name webcam

Howto change the name of the webcam. I’m using that one now for a cloudradar …

Hi
this is changed in the PWS_blocks under webcam. You can change it here to anything you like, but make sure that you change the line 1 to 09 as this then tells the pws updates that this is a modified block.
Also make a backup of PWS_blocks before you change the original just in case.

thnx :slight_smile: will change the name :slight_smile:

Check your Dutch translation file > https://www.weerstationmedemblik.nl/languages/lang_nl.txt

Line 612 now reads

|Web Cam|Webcam|

Change the right part to what you want to use. For instance

|Web Cam|Wolken radar|

You can do that for the most used languages for your website.

Succes,
Wim


@ ALL
Read https://pwsdashboard.com/documentation2012/26_languages.pdf
You can use those files to remove my typing errors a.s.o.

It also explains how to use less languages in your menu as only bots and script-kids are interested in all available languages.

hmm done as you said but still WebCam on the website.

in PWS_blocks change the line to whatever you want it to say.

The file is not updated on your server:

https://www.weerstationmedemblik.nl/languages/lang_nl.txt

Line 612 still reads

|Web Cam|Webcam|

There are only two lines with a word Webcam in that file.

Maybe you updated it local and did not upload it to your server?

Succes,
Wim

thats very strange, i change de file directly on the server not local…

The file is not refreshed automatically in a browser, but forcing to refresh showed your adaption.


BUT
Sorry we were adepting the wrong wording.
The “header line” in the first webcam block is in line 203 of that translation file

|LiveWebCam|WebCam|

change that line to

|LiveWebCam|Wolkenradar|

and it should show correctly.

Wim

1 Like

great job :slight_smile: thnx. case closed :slight_smile:

Can someone explain this more, I can’t seem to figure this out.

ReadMe https://pwsdashboard.com/documentation2012/26_languages.pdf

To change the name of the first webcam block
Go to the language folder f.i. for English pwsWD/languages/lang_en.txt
Add the following lines at the bottom of the file

# 2024-09-29
|Web Cam|The text you want|
|LiveWebCam|The text you want to use|

Default the webcams 2 and 3 will use the same texts

To change the name of the “optional” webcams.
Make a backup-copy of the PWS_blocks.php script
Change line 436 which now reads

$blck_ttls[$script] = $head_webcam;

to

$blck_ttls[$script] = lang(‘The text you want to use’);

For the third webcam block it is line 444 you need to change.


If you use more languages you better also adept the language files of the most used languages.

Add to the pwsWD/languages/lang_??.txt files

# 2024-09-29
|The text you want to use|The translation|

Hope this explains better, succes,
Wim

2 Likes

To change the name of the “optional” webcams.
Make a backup-copy of the PWS_blocks.php script
Change line 436 which now reads

$blck_ttls[$script] = $head_webcam;

to

$blck_ttls[$script] = lang(‘The text you want to use’);

For the third webcam block it is line 444 you need to change.


[/quote]

I tried the above and it broke the website. because one block is my tower cam and the other is regional radar. Is it possbile there is a formatting issue here?

$blck_ttls[$script] = lang(‘The text you want to use’);

I have four different cam blocks, to name them I did what Wim said, here is what it looks like:
webcam2 is
$blck_ttls[$script] = ‘Looking West’;
webcam3 is
$blck_ttls[$script] = ‘Looking South’;

What is the exact text you have on line 436 and line 444?

I am not 100% sure but I was copy and pasting and those right from your post and the apostrophe from the copy does not look the same as if I type it. That was what I saw different. Also not sure but after I saved something I tried refreshing the director on my local side before uploading. All is well now. Thank you.

An updated version with 3 webcam descriptions is available at the
Updates released after 2023-10-31 page

2024-04-19 Free download:
PWS_blocks.php.zip Added extra translations for webcam2+3 and soil-moist info

@ ALL
If you have downloaded/installed PwsDashboard before 2023 October 31 always run the PWS_updates.php script to download all updated scripts until that date.

If your version is up-to-date with this final version, check that Updates released after 2023-10-31 page first as all enhancements are posted there.

Regards,
Wim

1 Like