Jump to content

nscnick

Members
  • Posts

    13
  • Joined

  • Last visited

Everything posted by nscnick

  1. nscnick

    URLEncode

    Phew -- sorted it! Many thanks for the pointers.The functions are included in an 'invisible' directory, not accessible from Frontpage. After updating all of them the offending items no longer appear.The lack of real documentation on MS products speaks volumes.Once again thanks for the help.
  2. nscnick

    URLEncode

    I've obviously got some reading to do! The data in the database is correct and not encoded, which doesn't mean that in the process of outputting it hasn't been changed. I can't find any reference to a URLEncode function, so assume that Frontpage is doing it by default.While I acknowledge your 'icks', the apps are used because I have them and don't cost me any extra money, and up to now haven't been a problem as I am reasonably familiar with using them but don't do any code writing except under duress, I'm not a programmer, though can get by after a fashion.Thanks for the help, I may be back soon!
  3. nscnick

    URLEncode

    I have an access database which is searched through a Frontpage generated asp page SQL query. The problem is that it translates a web address hyperlink with a %2E instead of the period, even though the link itself is displayed on the browser page correctly.Does anybody have any ideas how this can be prevented or modified?This is the asp fragment that takes the access field (called www) containing the url:<td width="90" bgcolor="#CCFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"><p style="margin-top: 0; margin-bottom: 0"><font size="2"><b>website:</b></font><!--mstheme--></font></td><td width="547" bgcolor="#FFFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"><p style="margin-top: 0; margin-bottom: 0"><font size="2"> <a href="http://<%=FP_FieldURL(fp_rs,"www")%>"><!--webbotbot="DatabaseResultColumn" startspans-columnnames="ID,name,nameinit,title,fname,sname,position,address1,address2,address3,town,postcode,daytel,evetel,mob,fax,email,www,object,objectinit,aims,affiliation,membreq,agegps,charges,venue,times,wheelch,notes,remarks"s-column="www" b-tableformat="FALSE" b-hasHTML="FALSE" clientsidelocal_preview="<font size="-1">&lt;&lt;</font>www<font size="-1">&gt;&gt;</font>"preview="<font size="-1">&lt;&lt;</font>www<font size="-1">&gt;&gt;</font>" --><%=FP_FieldVal(fp_rs,"www")%><!--webbotbot="DatabaseResultColumn" i-CheckSum="7628" endspan --></a></font><!--mstheme--></font></td>The resulting viewable page after the query has run (in the browser) generates through View Source:<td width="547" bgcolor="#FFFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"><p style="margin-top: 0; margin-bottom: 0"><font size="2"> <a href="http://www%2Enscdesign%2Ecom">www.nscdesign.com</a></font><!--mstheme--></font></td>The output is a two column table of several fields arranged vertically from a single record. The other fields aren't shown above.I can see the %2E but am unsure how I can prevent this translation. This seems to be a result of what happens from the query output as putting a url directly into html doesn't produce the encoded periods. And the data in the database uses a period. So somewhere among the upper fragment the creation of the hyperlink from the data causes the problem.I wouldn't know where to start trying to work out what the asp fragment is doing.
  4. Apologies for the length of these bits but I'm notr sure what will or not be relevant (the asp is generated by Frontpage which is called as a result of the query and then obviously generates the resultant source code displayed on the browser - I managed to work that bit out for myself, but beyond that?). The asp page (with most of the output table row code deleted for simplicity)<html><head><meta http-equiv="Content-Language" content="en-gb"><meta http-equiv="Content-Type" content="text/html; charset=windows-1252"><meta name="GENERATOR" content="Microsoft FrontPage 4.0"><meta name="ProgId" content="FrontPage.Editor.Document"><title>BDetails</title><meta name="Microsoft Theme" content="sgrp 000, default"><meta name="Microsoft Border" content="tlb, default"></head><body bgcolor="#FFFFCC" text="#000000" link="#0000FF" vlink="#800080" alink="#CC6600"><!--msnavigation--><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td><!--mstheme--><font face="Arial, Arial, Helvetica"><div align="left" style="width: 825; height: 151"> <div align="center"> <center><!--mstheme--></font><pre style="margin-top: 0; margin-bottom: 0"> <img border="0" src="images/logos/small%20EU_pf_logo.gif" width="203" height="60"><font size="3"> </font><img border="0" src="images/logos/scvo.gif" width="55" height="59"><font size="3"> </font><a href="http://www.berryscotland.com"><img border="0" src="images/logos/berryscot.gif" width="216" height="45"></a><font face="Comic Sans MS" size="3"> </font><img border="0" src="images/logos/DirectGrantsLogo.gif" width="88" height="59"><font size="3"> </font><img border="0" src="images/logos/se_black.gif" width="172" height="60"></pre><!--mstheme--><font face="Arial, Arial, Helvetica"></center> </div> <center> <blockquote> <div align="center"> <!--mstheme--></font><pre style="margin-top: 0; margin-bottom: 0"><b><span style="text-transform: capitalize; font-variant: small-caps"><font face="Times New Roman" color="#0000FF" size="4"><img border="0" src="images/collogo_small.jpg" align="bottom" width="65" height="50"> </font><font color="#0000FF" face="Franklin Gothic Medium" size="6">S<span style="font-variant: small-caps; text-transform: capitalize">trathmore</span> & </font></span><font color="#0000FF" face="Franklin Gothic Medium" size="6">T<span style="font-variant: small-caps">he</span> G<span style="font-variant: small-caps">lens </span>R<span style="font-variant: small-caps">ural</span> P<span style="font-variant: small-caps">artnership</span></font></b> <b><font face="Times New Roman" color="#0000FF" size="4"><span style="text-transform: capitalize; font-variant: small-caps"><img border="0" src="images/collogo_small.jpg" align="bottom" width="66" height="50"></span></font></b></pre><!--mstheme--><font face="Arial, Arial, Helvetica"> </div> <div align="center"> <!--mstheme--></font><pre style="word-spacing: 0; margin-top: 0; margin-bottom: 0"><a href="http://www.perthshire.com"><img border="0" src="images/logos/Perthshireclassicscotland.gif" width="200" height="55"></a></pre><!--mstheme--><font face="Arial, Arial, Helvetica"> </div> </blockquote> </center></div><!--mstheme--></font></td></tr><!--msnavigation--></table><!--msnavigation--><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td valign="top" width="1%"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p></p><p align="center"><a href="http://newsrss.bbc.co.uk/rss/newsonline_uk_edition/scotland/rss.xml"><b>BBCNews</b></a></p><p style="margin-top: 1; margin-bottom: 3" align="center"><a href="http://www.google.com"><b><font color="#FF0000"><img border="0" src="images/logos/googlelogo.gif" width="89" height="39"></font></b></a></p><p style="margin-top: 1; margin-bottom: 3" align="center"><a href="http://www.bbc.co.uk/weather/5day.shtml?id=3066&links"><b><font face="Arial Narrow" color="#000000">StrathmoreWeather</font></b></a></p><p style="margin-top: 1; margin-bottom: 3" align="center"><a href="http://www.mwis.org.uk/index.php"><b><font face="Arial Narrow" color="#000000">MountainWeather</font></b></a></p><p><a href="images/walking.gif"><img border="0" src="images/walking_small.gif" width="100" height="75"></a></p><p><a href="images/lochmntns.gif"><img border="0" src="images/lochmntns_small.gif" width="100" height="75"></a></p><p><a href="images/trees.gif"><img border="0" src="images/trees_small.gif" width="100" height="75"></a></p><!--mstheme--></font></td><td valign="top" width="24"></td><!--msnavigation--><td valign="top"><!--mstheme--><font face="Arial, Arial, Helvetica"><p style="margin-top: 0; margin-bottom: 0"><a href="directory/busdirectory.htm" name="top">DirectoryIndex</a> <a href="index.htm">Home</a></p><p style="margin-top: 0; margin-bottom: 0"> </p><!--webbot bot="DatabaseRegionStart" startspans-columnnames="ID,name,nameinit,title,fname,sname,position,address1,address2,address3,town,postcode,daytel,evetel,mob,fax,email,www,object,objectinit,aims,affiliation,membreq,agegps,charges,venue,times,wheelch,notes,remarks"s-columntypes="3,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202,202"s-dataconnection="business" b-tableformat="FALSE" b-menuformat="FALSE"s-menuchoice="name" s-menuvalue="name" b-tableborder="TRUE" b-tableexpand="TRUE"b-tableheader="TRUE" b-listlabels="TRUE" b-listseparator="FALSE"i-ListFormat="0" b-makeform="FALSE" s-recordsource="Table1"s-displaycolumns="name,title,fname,sname,position,address1,address2,address3,town,postcode,daytel,evetel,mob,fax,email,www,object"s-criteria="[name] EQ {name} +" s-orders-sql="SELECT * FROM Table1 WHERE (name = '::name::')" b-procedure="FALSE"clientside SuggestedExt="asp" s-DefaultFields="name="s-NoRecordsFound="No records returned." i-MaxRecords="1" i-GroupSize="0"BOTID="0" u-dblib="_fpclass/fpdblib.inc" u-dbrgn1="_fpclass/fpdbrgn1.inc"u-dbrgn2="_fpclass/fpdbrgn2.inc" tag="BODY"local_preview="<table border=0 width="100%"><tr><td bgcolor="#FFFF00" align="left"><font color="#000000">Database Results regions will not preview unless this page is fetched from a Web server using a web browser. The section of the page from here to the end of the Database Results region will repeat once for each record returned by the query.</font></td></tr></table>"preview="<table border=0 width="100%"><tr><td bgcolor="#FFFF00" align="left"><font color="#000000">This is the start of a Database Results region. The page must be fetched from a web server with a web browser to display correctly; the current web is stored on your local disk or network.</font></td></tr></table>" b-WasTableFormat="FALSE" --><!--#include file="_fpclass/fpdblib.inc"--><%fp_sQry="SELECT * FROM Table1 WHERE (name = '::name::')"fp_sDefault="name="fp_sNoRecords="No records returned."fp_sDataConn="business"fp_iMaxRecords=1fp_iCommandType=1fp_iPageSize=0fp_fTableFormat=Falsefp_fMenuFormat=Falsefp_sMenuChoice="name"fp_sMenuValue="name"fp_iDisplayCols=17fp_fCustomQuery=FalseBOTID=0fp_iRegion=BOTID%><!--#include file="_fpclass/fpdbrgn1.inc"--><!--webbot bot="DatabaseRegionStart" i-CheckSum="57526" endspan --><!--mstheme--></font><table border="0" width="661" height="294"> <tr>.....The other field items have been deleted between the periods to make it shorter! They are are records within an html two column tableText in the LH, and the field results textbox in the RH..... <td width="90" bgcolor="#CCFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p style="margin-top: 0; margin-bottom: 0"><font size="2"><b>website:</b></font><!--mstheme--></font></td> <td width="547" bgcolor="#FFFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p style="margin-top: 0; margin-bottom: 0"><font size="2"> <a href="http://<%=FP_FieldURL(fp_rs,"www")%>"><!--webbot bot="DatabaseResultColumn" startspan s-columnnames="ID,name,nameinit,title,fname,sname,position,address1,address2,address3,town,postcode,daytel,evetel,mob,fax,email,www,object,objectinit,aims,affiliation,membreq,agegps,charges,venue,times,wheelch,notes,remarks" s-column="www" b-tableformat="FALSE" b-hasHTML="FALSE" clientside local_preview="<font size="-1">&lt;&lt;</font>www<font size="-1">&gt;&gt;</font>" preview="<font size="-1">&lt;&lt;</font>www<font size="-1">&gt;&gt;</font>" --><%=FP_FieldVal(fp_rs,"www")%><!--webbot bot="DatabaseResultColumn" i-CheckSum="7628" endspan --> </a> </font><!--mstheme--></font></td> </tr> ..... .....</table><!--mstheme--><font face="Arial, Arial, Helvetica"><!--webbot bot="DatabaseRegionEnd" startspan b-tableformat="FALSE"b-menuformat="FALSE" u-dbrgn2="_fpclass/fpdbrgn2.inc" i-groupsize="0" clientsidetag="BODY"local_preview="<table border=0 width="100%"><tr><td bgcolor="#FFFF00" align="center"><font color="#000000">End of Database Results region.</font></td></tr></table>"preview="<table border=0 width="100%"><tr><td bgcolor="#FFFF00" align="left"><font color="#000000">This is the end of a Database Results region.</font></td></tr></table>" --><!--#include file="_fpclass/fpdbrgn2.inc"--><!--webbot bot="DatabaseRegionEnd" i-CheckSum="62730" endspan --><p align="left"><a href="directory/busdirectory.htm">DirectoryIndex</a> <a href="index.htm">Home</a> <a href="#top">Top</a></p><p align="left"> <!--mstheme--></font><!--msnavigation--></td></tr><!--msnavigation--></table><!--msnavigation--><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td><!--mstheme--><font face="Arial, Arial, Helvetica"><!--mstheme--></font></td></tr><!--msnavigation--></table></body></html>The HTML source (obtained through View Source on the Browser, as above with the non-problem field rows removed):<html><head><meta http-equiv="Content-Language" content="en-gb"><meta http-equiv="Content-Type" content="text/html; charset=windows-1252"><meta name="GENERATOR" content="Microsoft FrontPage 4.0"><meta name="ProgId" content="FrontPage.Editor.Document"><title>BDetails</title><meta name="Microsoft Theme" content="sgrp 000, default"><meta name="Microsoft Border" content="tlb, default"></head><body bgcolor="#FFFFCC" text="#000000" link="#0000FF" vlink="#800080" alink="#CC6600"><!--msnavigation--><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td><!--mstheme--><font face="Arial, Arial, Helvetica"><div align="left" style="width: 825; height: 151"> <div align="center"> <center><!--mstheme--></font><pre style="margin-top: 0; margin-bottom: 0"> <img border="0" src="images/logos/small%20EU_pf_logo.gif" width="203" height="60"><font size="3"> </font><img border="0" src="images/logos/scvo.gif" width="55" height="59"><font size="3"> </font><a href="http://www.berryscotland.com"><img border="0" src="images/logos/berryscot.gif" width="216" height="45"></a><font face="Comic Sans MS" size="3"> </font><img border="0" src="images/logos/DirectGrantsLogo.gif" width="88" height="59"><font size="3"> </font><img border="0" src="images/logos/se_black.gif" width="172" height="60"></pre><!--mstheme--><font face="Arial, Arial, Helvetica"></center> </div> <center> <blockquote> <div align="center"> <!--mstheme--></font><pre style="margin-top: 0; margin-bottom: 0"><b><span style="text-transform: capitalize; font-variant: small-caps"><font face="Times New Roman" color="#0000FF" size="4"><img border="0" src="images/collogo_small.jpg" align="bottom" width="65" height="50"> </font><font color="#0000FF" face="Franklin Gothic Medium" size="6">S<span style="font-variant: small-caps; text-transform: capitalize">trathmore</span> & </font></span><font color="#0000FF" face="Franklin Gothic Medium" size="6">T<span style="font-variant: small-caps">he</span> G<span style="font-variant: small-caps">lens </span>R<span style="font-variant: small-caps">ural</span> P<span style="font-variant: small-caps">artnership</span></font></b> <b><font face="Times New Roman" color="#0000FF" size="4"><span style="text-transform: capitalize; font-variant: small-caps"><img border="0" src="images/collogo_small.jpg" align="bottom" width="66" height="50"></span></font></b></pre><!--mstheme--><font face="Arial, Arial, Helvetica"> </div> <div align="center"> <!--mstheme--></font><pre style="word-spacing: 0; margin-top: 0; margin-bottom: 0"><a href="http://www.perthshire.com"><img border="0" src="images/logos/Perthshireclassicscotland.gif" width="200" height="55"></a></pre><!--mstheme--><font face="Arial, Arial, Helvetica"> </div> </blockquote> </center></div><!--mstheme--></font></td></tr><!--msnavigation--></table><!--msnavigation--><table dir="ltr" border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td valign="top" width="1%"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p></p><p align="center"><a href="http://newsrss.bbc.co.uk/rss/newsonline_uk_edition/scotland/rss.xml"><b>BBCNews</b></a></p><p style="margin-top: 1; margin-bottom: 3" align="center"><a href="http://www.google.com"><b><font color="#FF0000"><img border="0" src="images/logos/googlelogo.gif" width="89" height="39"></font></b></a></p><p style="margin-top: 1; margin-bottom: 3" align="center"><a href="http://www.bbc.co.uk/weather/5day.shtml?id=3066&links"><b><font face="Arial Narrow" color="#000000">StrathmoreWeather</font></b></a></p><p style="margin-top: 1; margin-bottom: 3" align="center"><a href="http://www.mwis.org.uk/index.php"><b><font face="Arial Narrow" color="#000000">MountainWeather</font></b></a></p><p><a href="images/walking.gif"><img border="0" src="images/walking_small.gif" width="100" height="75"></a></p><p><a href="images/lochmntns.gif"><img border="0" src="images/lochmntns_small.gif" width="100" height="75"></a></p><p><a href="images/trees.gif"><img border="0" src="images/trees_small.gif" width="100" height="75"></a></p><!--mstheme--></font></td><td valign="top" width="24"></td><!--msnavigation--><td valign="top"><!--mstheme--><font face="Arial, Arial, Helvetica"><p style="margin-top: 0; margin-bottom: 0"><a href="directory/busdirectory.htm" name="top">DirectoryIndex</a> <a href="index.htm">Home</a></p><p style="margin-top: 0; margin-bottom: 0"> </p><!--mstheme--></font><table border="0" width="661" height="294">......Output rows deleted...... <tr> <td width="90" bgcolor="#CCFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p style="margin-top: 0; margin-bottom: 0"><font size="2"><b>website:</b></font><!--mstheme--></font></td> <td width="547" bgcolor="#FFFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p style="margin-top: 0; margin-bottom: 0"><font size="2"> <a href="http://www%2Enscdesign%2Ecom">www.nscdesign.com </a> </font><!--mstheme--></font></td> </tr>......Output rows deleted...... </table><!--mstheme--><font face="Arial, Arial, Helvetica"><p align="left"><a href="directory/busdirectory.htm">DirectoryIndex</a> <a href="index.htm">Home</a> <a href="#top">Top</a></p><p align="left"> <!--mstheme--></font><!--msnavigation--></td></tr><!--msnavigation--></table><!--msnavigation--><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td><!--mstheme--><font face="Arial, Arial, Helvetica"><!--mstheme--></font></td></tr><!--msnavigation--></table></body></html>
  5. This is the asp fragment that takes the access field (called www) containing the url:s-column="www" b-tableformat="FALSE" b-hasHTML="FALSE" clientside local_preview="<font size="-1">&lt;&lt;</font>www<font size="-1">&gt;&gt;</font>" preview="<font size="-1">&lt;&lt;</font>www<font size="-1">&gt;&gt;</font>" --><%=FP_FieldVal(fp_rs,"www")%><!--webbot bot="DatabaseResultColumn" i-CheckSum="7628" endspan -->The resulting viewable page (in the browser) generates as source code:<td width="547" bgcolor="#FFFFFF" height="18"><!--mstheme--><font face="Arial, Arial, Helvetica"> <p style="margin-top: 0; margin-bottom: 0"><font size="2"> <a href="http://www%2Enscdesign%2Ecom">www.nscdesign.com </a> </font><!--mstheme--></font></td>I can see the %2E but am unsure how I can change these for the period. There doesn't seem to anything like a URL 'unencode', or should I be looking at asp to do this? I suppose I could write a scan and replace the characters but wouldn't know how to insert into the asp page. This seems to be a result of what happens from the database as putting a url directly into html doesn't produce the encoded periods. So somewhere along the upper fragment generates this change.I wouldn't know where to start trying to work out what the asp fragment is doing.
  6. I have an access database which is searched through a frontpage generated asp page SQL query. The problem is that it translates a web address hyperlink with a %2E instead of the period, even though the link is displayed on the page correctly.Does anybody have any ideas how this can be prevented? I cannot see any immediately obvious locations in the html.
  7. Yes thanks, it was me. I wasn't sure if there was an html solution as an alternative. However I did find out that the method turns a number into a string!Problem now solved, thanks for all help.
  8. And after a lot of experimentation I discovered that it converts the number to a string! So I needed an interim value for display purposes to go into the html text box, so that the running total stayed a number!Got there in the end.
  9. Many many thanks.I couldn't find a similar function/method in the w3schools!Wonderful what peer support can do, thanks again.
  10. Thanks for the pointers. I had seen this but it doesn't force decimal places, (much as an Excel cell can). I think I can do it in VB but don't know if it is possible to spawn out to another file within js.I have tried using two decimal places in default figures but if an integer is put in (such as ordering a qty of an item) then the result ends up as an integer or one decimal place.The problem is that I want to display the result of a currency calculation, which needs the minor units.
  11. HiI am using the result of a js calculation in an html table, and would like to be able to force decimal places to show currencies. Is there a way of doing this? I can't find any function references or formatting information for html, or would I need to to use something else?Many thanks for any help received.
  12. HiI am trying to format numbers, to display currencies with 2 decimal places. However, I can set the initial value fine but after any calculation it reverts to integer or uncontrolled decimal. These are for display in a table text box or similar.Any help is gratefully received.
×
×
  • Create New...