wviewweather.com Forum Index wviewweather.com
wview and Weather Topics
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

HTML Templates and Extended Sensor Support

 
Post new topic   Reply to topic    wviewweather.com Forum Index -> Web Sites and HTML Templates
View previous topic :: View next topic  
Author Message
mteel



Joined: 30 Jun 2005
Posts: 435
Location: Collinsville, TX

PostPosted: Thu Aug 04, 2005 6:43 am    Post subject: HTML Templates and Extended Sensor Support Reply with quote

The purpose of this is to reproduce information found in several places in the wview distro and bring it all together for configuring your wview installation. The main thing to remember is configuring wview for extended sensor support when running wviewconfig, editing your /etc/wview/html-templates.conf file and then editing your three html template files to remove the sensor images for sensors you DO NOT have.


***>>> From the wview User's Manual, section 12:

12.2.2 images.conf or images-metric.conf

12.2.2.1 If this is a new install, skip to 12.2.2.2. To upgrade, you will need
to copy the new extended data image definitions from the distribution
example file images.conf (images-metric.conf) found in
.../wview-x.y.z/examples/conf.
The new definitions begin with the heading:
"################# V P P L U S D A T A B U C K E T S #################"
Copy all definitions below this heading to your existing images.conf
(images-metric.conf) file.
12.2.2.2 Edit /etc/wview/images.conf (images-metric.conf if a metric station)
12.2.2.3 Starting at the VP Plus Data Buckets header, enable all desired sensor
images by removing all "#" characters from the beginning of the line.
Remember, if you don't have the physical sensor installed on your
station, you should not enable the corresponding images for it - it
only wastes resources. At a minimum, it is safe to enable Radiation,
UV and ET images if you have a Plus station.
12.2.2.4 For each new image you have enabled, translate or edit the title and
units strings as needed (no spaces in the units label).
12.2.2.5 Save and Exit the editor

12.2.3 html-templates.conf

12.2.3.1 Edit /etc/wview/html-templates.conf
12.2.3.2 Replace the corresponding old references with:

Current_Conditions_Plus.htx
Daily_Vantage_Pro_Plus.htx
Monthly_Vantage_Pro_Plus.htx
Yearly_Vantage_Pro_Plus.htx

Leave index.htx unchanged.
12.2.3.3 Save and Exit the editor

12.2.4 index.htx

Copy the Plus index.htx template over the standard file:
cp /etc/wview/html/index_Plus.htx /etc/wview/html/index.htx

Edit the index.htx file as usual to customize for your station,
language and content preferences.

12.2.5 Current_Vantage_Pro_Plus.htx

12.2.5.1 If upgrading, copy the example Current_Vantage_Pro_Plus.htx file from
the distribution to your wview config tree:
cp wview-x.y.z/examples/html/Current_Vantage_Pro_Plus.htx /etc/wview/html
12.2.5.2 Edit /etc/wview/html/Current_Vantage_Pro_Plus.htx as usual to customize
for your station, language and content preferences.
12.2.5.3 Save and Exit the editor

12.2.6 Daily_Vantage_Pro_Plus.htx

12.2.6.1 If upgrading, copy the example Daily_Vantage_Pro_Plus.htx file from
the distribution to your wview config tree:
cp wview-x.y.z/examples/html/Daily_Vantage_Pro_Plus.htx /etc/wview/html
12.2.6.2 Edit /etc/wview/html/Daily_Vantage_Pro_Plus.htx
12.2.6.3 Delete all extended data image references that are NOT supported by

your station. Find the comment lines:
!-- ***** Extended Data Begin ***** --
...
[extended sensor image references]
...
!-- ***** Extended Data End ***** --
and delete all non-supported sensor images. The extended sensor images
remaining should match the "Day" images you enabled in images.conf
(images-metric.conf).
12.2.6.4 Edit /etc/wview/html/Daily_Vantage_Pro_Plus.htx as usual to customize
for your station, language and content preferences.
12.2.6.5 Save and Exit the editor

12.2.7 Monthly_Vantage_Pro_Plus.htx

12.2.7.1 If upgrading, copy the example Monthly_Vantage_Pro_Plus.htx file from
the distribution to your wview config tree:
cp wview-x.y.z/examples/html/Monthly_Vantage_Pro_Plus.htx /etc/wview/html
12.2.7.2 Edit /etc/wview/html/Monthly_Vantage_Pro_Plus.htx
12.2.7.3 Delete all extended data image references that are NOT supported by
your station. Find the comment lines:
!-- ***** Extended Data Begin ***** --
...
[extended sensor image references]
...
!-- ***** Extended Data End ***** --
and delete all non-supported sensor images. The extended sensor images
remaining should match the "Month" images you enabled in images.conf
(images-metric.conf).
12.2.7.4 Edit /etc/wview/html/Monthly_Vantage_Pro_Plus.htx as usual to customize
for your station, language and content preferences.
12.2.7.5 Save and Exit the editor

12.2.8 Yearly_Vantage_Pro_Plus.htx

12.2.8.1 If upgrading, copy the example Yearly_Vantage_Pro_Plus.htx file from
the distribution to your wview config tree:
cp wview-x.y.z/examples/html/Yearly_Vantage_Pro_Plus.htx /etc/wview/html
12.2.8.2 Edit /etc/wview/html/Yearly_Vantage_Pro_Plus.htx
12.2.8.3 Delete all extended data image references that are NOT supported by
your station. Find the comment lines:
!-- ***** Extended Data Begin ***** --
...
[extended sensor image references]
...
!-- ***** Extended Data End ***** --
and delete all non-supported sensor images. The extended sensor images
remaining should match the "Year" images you enabled in images.conf
(images-metric.conf).
12.2.8.4 Edit /etc/wview/html/Yearly_Vantage_Pro_Plus.htx as usual to customize
for your station, language and content preferences.
12.2.8.5 Save and Exit the editor

***>>> From the example html-templates.conf (to be edited in /etc/wview):

### Use these for Vantage Pro Plus Extended Data
### Remember to rename "index_Plus.htx" to "index.htx" in the /etc/wview/html
### directory for UV and ET display on the home page and URL references to
### these pages...
# Current_Conditions_Plus.htx
# Daily_Vantage_Pro_Plus.htx
# Monthly_Vantage_Pro_Plus.htx
# Yearly_Vantage_Pro_Plus.htx

# Home Page template, do not remove unless you are using the day/night
# alternative below
index.htx

# Daytime/Nighttime Home Pages - if you want a different homepage template
# based on day or night, uncomment these and copy your templates to
# /etc/wview/html/index-day.htx and /etc/wview/html/index-night.htx respectively
# index-day.htx
# index-night.htx


# Add, remove or modify as needed
Current_Conditions.htx
Current_Vantage_Pro.htx
Daily_Vantage_Pro.htx
Monthly_Vantage_Pro.htx
Yearly_Vantage_Pro.htx
Back to top
View user's profile Send private message Send e-mail Visit poster's website
IslandLife



Joined: 30 Jul 2005
Posts: 58
Location: Guam (USA)

PostPosted: Sat Oct 08, 2005 12:58 am    Post subject: Reply with quote

I've followed all the VP2 directions to a tee (T?) a couple of times, but I can not get the program to generate the *_vantage_pro_plus.html files that are needed. Anyone with MacOS X been successful in getting them generated?

Thanks,
Paul

<http://www.pcrguam.com/img/index.html
Back to top
View user's profile Send private message Visit poster's website
mteel



Joined: 30 Jun 2005
Posts: 435
Location: Collinsville, TX

PostPosted: Sat Oct 08, 2005 5:45 am    Post subject: Reply with quote

Post your html-templates.conf file here and a directory listing of your /etc/wview/html directory.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
IslandLife



Joined: 30 Jul 2005
Posts: 58
Location: Guam (USA)

PostPosted: Sat Oct 08, 2005 6:23 am    Post subject: Reply with quote

mteel wrote:
Post your html-templates.conf file here and a directory listing of your /etc/wview/html directory.


#
# html-templates.conf - define the HTML template files to use for HTML
# generation
#

# File Format
#
# 1) lines beginning with '#' or <blank> are ignored
#

# Column Format
#
# 1) template file name (must be in /etc/wview/html)
#


###############################################################################
### Home Page Templates
###############################################################################

### Standard Home Page template, do not remove unless you are using the
### day/night alternative below
index.htx

### Day/Night Home Pages - if you want a different homepage template based on
### day or night, uncomment these and copy your templates to
### /etc/wview/html/index-day.htx and /etc/wview/html/index-night.htx
### respectively
#index-day.htx
#index-night.htx


###############################################################################
### Almanac Template
###############################################################################

almanac.htx


###############################################################################
### Historical Data Templates
###############################################################################

### Standard (no extra sensors) Vantage Pro Data
Current_Conditions_Plus.htx
Daily_Vantage_Pro_Plus.htx
Monthly_Vantage_Pro_Plus.htx
Yearly_Vantage_Pro_Plus.htx

### Vantage Pro Plus (or extra sensor) Extended Data
### Remember to rename "index_Plus.htx" to "index.htx" in the /etc/wview/html
### directory for UV and ET display on the home page and URL references to
### these pages...



###############################################################################
### Current Conditions (Table Only) Template
###############################################################################

#Current_Conditions.htx

Directory listing below. Sorry I can't get it to show up as the 2 column table it is.
G5-Tower:/etc/wview/html paul$ ls
Current_Conditions.htx index-classic.htx
Current_Vantage_Pro.htx index-classic_Plus.htx
Current_Vantage_Pro_Plus.htx index-clouds.htx
Daily_Vantage_Pro.htx index-darkblue.htx
Daily_Vantage_Pro_Plus.htx index-day.htx
Monthly_Vantage_Pro.htx index-dusky.htx
Monthly_Vantage_Pro_Plus.htx index-leaves.htx
Yearly_Vantage_Pro.htx index-night.htx
Yearly_Vantage_Pro_Plus.htx index.htx
almanac.htx index_Plus.htx
data.htx parameterlist.txt
index-above-clouds.htx rotate-index.sh


Thanks!
Back to top
View user's profile Send private message Visit poster's website
mteel



Joined: 30 Jun 2005
Posts: 435
Location: Collinsville, TX

PostPosted: Sat Oct 08, 2005 6:35 am    Post subject: Reply with quote

Since you have "Current_Conditions_Plus.htx" listed in your conf file but no such file in your templates directory (/etc/wview/html), it is probably failing at that file and not continuing... Comment out that entry - you are not using it anywhere anyway. Everything else looks fine...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
IslandLife



Joined: 30 Jul 2005
Posts: 58
Location: Guam (USA)

PostPosted: Sat Oct 08, 2005 2:33 pm    Post subject: Reply with quote

mteel wrote:
Since you have "Current_Conditions_Plus.htx" listed in your conf file but no such file in your templates directory (/etc/wview/html), it is probably failing at that file and not continuing... Comment out that entry - you are not using it anywhere anyway. Everything else looks fine...


That was it! All is well now. Great App!
Back to top
View user's profile Send private message Visit poster's website
mteel



Joined: 30 Jun 2005
Posts: 435
Location: Collinsville, TX

PostPosted: Sat Oct 08, 2005 3:56 pm    Post subject: Reply with quote

I just changed the HTML file generation so it will just complain about the failure but continue to generate the remaining files. It will be in the next release, whenever that is...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    wviewweather.com Forum Index -> Web Sites and HTML Templates All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group