GenoPro Home
GenoPro Home  |  Get Started With My Genealogy Tree  |  Buy  |  Login  |  Privacy  |  Search  |  Site Map
 

GenoPro Support Forum




Author
Posted Monday, August 13, 2007 - Post #18837
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 2 days ago @ 10:27 PM
Posts: 3,429, Visits: 26,550
I have finally managed to get some scripting finished for the calendar feature. Attached is an English Narrative Report skin with it included. Also attached in a 'standalone' calendar skin 'calandarskin.zip' that can be used as a custom skin to generate the data to populate a calendar on your own web page. It is based on a pared down version of Narrative skin  and has a modified Config.xml that includes just two template files, Init.htm and calendarevents.js. The skin generates two other files in addition to calendarevents.js , layercalendar.js which is a modified version of Rick Pike's script and a prototype calendar.htm file that you can use as the basis of your own web page. Note that in order for the hyperlinks to work you will need to change the 'base' tag href attribute to point to the URL where your Narrative Report pages are located.

Both reports take fixed text , including month & day names, from Dictionary.xml so that it can be translated to other languages if required.

I have some more work to do on the calendar at a later date. I would like the styling to be handled via the style.css stylesheet rather than being hardcoded in layercalendar.js. Also it should perhaps generate two or more years of birthdays/anniversaries rather than one year as at present.

Update 24/08/07 Amended skins



'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"


calendarskin.zip (94 views, 87.47 KB)

Edited: Friday, August 24, 2007 by Ron
Posted Monday, August 13, 2007 - Post #18838
Forum Guru

Forum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum Guru

Customers
Translator
GenoPro version: 3.1.0.1

Last Login: Thursday, May 8, 2025
Posts: 103, Visits: 2,091
Hi Ron,

I got the following error, but it's only on my famili tree:

Error en la línea 37, posición 2 (calendarevents.js): No coinciden los tipos: '[string: "(null)"]' Error de Microsoft VBScript en tiempo de ejecución 800A000D

 I tried with other sample files and there's no generation problem, but I can't see the calendar in the generated report, is there any additional required plugin?

Line: 26
Char: 1
Error: Object expected
Code: 0
Url: calendar.htm

PS.I'm using IE6SP2, GenoPro2.0.0.9, Skin 2.0.1.0.RC4

Thanks,

Hugo

Posted Monday, August 13, 2007 - Post #18839
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 2 days ago @ 10:27 PM
Posts: 3,429, Visits: 26,550
Thanks Hugo. I was perhaps a bit hasty in posting (as usual!). I had only tested with Firefox which works fine. As you have found IE (I tried IE7) doesn't display the calendar. I'll work on the IE issue. Don't you just love cross-browser compatibility! Crazy

As regards your first problem, possibly you have a marriage date without any year? I will need to check for this.


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"
Posted Monday, August 13, 2007 - Post #18841
Forum Guru

Forum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum Guru

Customers
Translator
GenoPro version: 3.1.0.1

Last Login: Thursday, May 8, 2025
Posts: 103, Visits: 2,091
Ron (8/13/2007)
Thanks Hugo. I was perhaps a bit hasty in posting (as usual!). I had only tested with Firefox which works fine. As you have found IE (I tried IE7) doesn't display the calendar. I'll work on the IE issue. Don't you just love cross-browser compatibility! Crazy

As regards your first problem, possibly you have a marriage date without any year? I will need to check for this.

Many thanks Ron, you are right, it's a marriage date without year. Smile

I also download a firefox browser, so I can finally see it... HeheIt's a perfect solution for somebody like me with a non-stick memory... (I always forget almost all birthdays TongueSmile Congratulations Ron! It's excellent. Smile

A suggestion... the calendar it's only filled from the generation date and on... could it be filled from the beginning of the year? or at least from the beginning of the current month?

Regards,

Hugo

Posted Monday, August 13, 2007 - Post #18843
Forum Master

Forum MasterForum MasterForum MasterForum MasterForum MasterForum MasterForum MasterForum MasterForum Master

Customers
Important Contributors
FamilyTrees.GenoPro.com
Translator
GenoPro version: 3.1.0.1

Last Login: Sunday, March 21, 2021
Posts: 716, Visits: 12,927
Well done Ron and thanks a lot.
But can you please look again into the background color of the calendar table. Now it is transparent and if the overall background of your pages does not match, the calendar does not look nice. My suggestion is to fix the background of the calendar table(days) to the beige level (in calendar.htm), the same as if your overall background has no background at all. Easy to check if you change the background in the style sheet. Changed this in my report.

Ron, tried the calendar for a Japanese report, which did not work properly with regard to the links. Japanese characters are not used in file names and it will use either the full name plus ID or only the ID for individuals and family-and-famID for families or a complete filename, depending on the couples` names.


Edited: Monday, August 13, 2007 by maru-san
Posted Tuesday, August 14, 2007 - Post #18844
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 2 days ago @ 10:27 PM
Posts: 3,429, Visits: 26,550
After nearly tearing my hair out I have finally discovered the cause of the IE failure. Rather an obscure error that was not flagged. (For the technically-minded I had used a reserved word, export, as an identifier in an object literal. IE discarded the script file, Firefox didn't mind. Amended skins are attached to my earlier post. Also fixed issue with birth/marriage dates with no year. I will work on further improvements as time permits. Ideally I'd like to have tabs for months rather than the existing hyperlinks.

maru-san (8/13/2007)
But can you please look again into the background color of the calendar table. Now it is transparent and if the overall background of your pages does not match, the calendar does not look nice.

I looked into this and discovered a # missing before the colour code in layercalendar.js so should be OK now. There will be more control once I convert to using CSS styles.


Ron, tried the calendar for a Japanese report, which did not work properly with regard to the links. Japanese characters are not used in file names and it will use either the full name plus ID or only the ID for individuals and family-and-famID for families or a complete filename, depending on the couples` names.

I need Dan to look at this and tell me how the html filenames are generated by GenoPro. In the Narrative report they are available in the 'Href' property but this is blank in the standaalone report, hence the requirement to generate them. Currently I just strip accents & punctuation and use the outputfile template from Config.xml


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"


Edited: Tuesday, August 14, 2007 by Ron
Posted Tuesday, August 14, 2007 - Post #18845
Famous Writer

Famous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous Writer

Customers
Important Contributors
GenoPro version: 3.0.0.7

Last Login: Sunday, November 26, 2023
Posts: 213, Visits: 4,464
Thanks Ron

When I was trying to generate a report using the new skins, I could see the calender but not the events. The same problem also on the Stand-Alone version.

The Calendarevents.js, is not containing any data except :

months=['','January','February','March','April','May','June','July','August','September','October','November','December'];
weekdays=['','Sun','Mon','Tue','Wed','Thu','Fri','Sat'];
oDic = {
'view':'View',
'changes':'Apply changes',
'print':'Printer friendly',
'export':'Export events displayed',
'filter':'Filter events',
'jump':'Jump to month'}

Of course , The GNO file that I used, was with many individuals and dates.

Posted Tuesday, August 14, 2007 - Post #18846
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 2 days ago @ 10:27 PM
Posts: 3,429, Visits: 26,550
Hum, the calendar only has 'live' events i.e. birthdays for those still alive and anniversaries for couples still together. Dates must be complete dates with day month & year.

There could be an issue with locale. The script uses the vbscript function IsDate to check for valid dates. Does your Windows locale match your GenoPro date formats? Perhaps I should recode to avoid IsDate.

Update: scripts amended to avoid IsDate


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"


Edited: Tuesday, August 14, 2007 by Ron
Posted Tuesday, August 14, 2007 - Post #18850
Famous Writer

Famous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous WriterFamous Writer

Customers
Important Contributors
GenoPro version: 3.0.0.7

Last Login: Sunday, November 26, 2023
Posts: 213, Visits: 4,464
Ron (8/14/2007)
Hum, the calendar only has 'live' events i.e. birthdays for those still alive and anniversaries for couples still together. Dates must be complete dates with day month & year.

There could be an issue with locale. The script uses the vbscript function IsDate to check for valid dates. Does your Windows locale match your GenoPro date formats? Perhaps I should recode to avoid IsDate.

Update: scripts amended to avoid IsDate

 

I went to the Control Panel of WinXP and changed the date format from Hebrew to English(US). Now I can see the events.

 On RC6 it seems to work also on the Hebrew date format only on one of my gno files. I tried to generate the report from a big GNO, and it's not working. I can't see the events. I attach the file.

I've also noticed that it's possible to see only future events. for example: My birthday is on 23 Feb. I could see this event only at 23 Feb 2008 and not at 23 Feb 2007 (Current year).

Also, when I click on the event link, it goes to "Harry Potter" family tree and not to my tree.(I've checked the stand-alone version) 

on the full skin, the link is broken.

calendarevents.js (56 views, 123.21 KB)

Edited: Tuesday, August 14, 2007 by beraha

Posted Tuesday, August 14, 2007 - Post #18851
Forum Guru

Forum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum Guru

Customers
Translator
GenoPro version: 3.1.0.1

Last Login: Thursday, May 8, 2025
Posts: 103, Visits: 2,091
Hi Ron,

I found a problem in the distribution of the days in the table     
If the months are translated in the dictionary.xml file, then the script doesn't find the correct month, and make a bad distribution on the table (the first day of the month always begins in Sunday )

<-- Ver JulioAgosto 2007 Ver Septiembre -->
DomLunMarMieJueVierSab
1  
2  
3  
4  
5  
6  
7  
8  
9  
10 
11 
12 
13 
14 

If the months are not translated, then it's ok...

<-- Ver JulyAugust 2007 Ver September -->
DomLunMarMieJueVierSab
   
1  
2  
3  
4  
5  
6  
7  
8  
9  
10 
11 

Ron (8/14/2007)
I need Dan to look at this and tell me how the html filenames are generated by GenoPro. In the Narrative report they are available in the 'Href' property but this is blank in the standaalone report, hence the requirement to generate them. Currently I just strip accents & punctuation and use the outputfile template from Config.xml

Also I found that some links are not working in the calendar (Narrative_2.0.1.0RC5.zip) , so I compare the links and I found this:
In aniversaries, missing the prefix "family-"
file:///C:/Familiograma/VictorOrtizFloresElizabethEsquivelCervantes-fam00019.htm --calendar link
file:///C:/Familiograma/family-VictorOrtizFloresAndElizabethEsquivelCervantes-fam00019.htm --in any other part in the report


Missing dot
file:///C:/Familiograma/Melgar-MaEstela-ind00531.htm --calendar link
file:///C:/Familiograma/Melgar-Ma.Estela-ind00531.htm  ----in any other part in the report

file:///C:/Familiograma/Martagon-MadelCarmen-ind00251.htm --calendar link
file:///C:/Familiograma/Martagon-Ma.delCarmen-ind00251.htm --in any other part in the report


The "ñ" is replaced with "n"
file:///C:/Familiograma/Carca%C3%B1o-Dolores-ind00331.htm --calendar link
file:///C:/Familiograma/Carcano-Dolores-ind00331.htm  --in any other part in the report

if name is missing then there should be only one "-"
file:///C:/Familiograma/Morales--ind01417.htm  --calendar link
file:///C:/Familiograma/Morales-ind01417.htm  --in any other part in the report

Regards,

Hugo



Similar Topics

Click to view RSS...
Expand / Collapse

Reading This Topic

Expand / Collapse
Active: 2 - 1 guest, 0 members, 0 anonymous.
Refresh
No members currently viewing this topic!