Re: [WebDNA] Passing a text variable via copyfile

This WebDNA talk-list message is from

2019


It keeps the original formatting.
numero = 114906
interpreted = N
texte = 2534 ------=_Part_2978911_1887828090.1570444912043 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable I achieved everything that I needed using [writefile].=C2=A0[text] variabl= e passed from the form into the new page succesfully etc. I did things that way about 5-7 years ago and this time around I just thoug= ht [copyfile] was the way to go, but it didn't seem to be after I located t= hose old pages and looked them over. And yes I did have to sprinkle [raw][/raw] here and there within the html c= ode being written into a new file. The last reference to the an error I kept getting:=C2=A0 Error: Error: expe= cted [/IF], but found [/writefile] instead[/writefile] Was being generated by the following javascript within the stuff being writ= ten to the new page, and not because I messed up some webdna code: =C2=A0 =C2=A0=C2=A0 =C2=A0 I kept looking at webdna code thinking I messed something up and never look= ed twice at that javascript thinking I needed to [raw][/raw] it. Once I surrounded it with [raw][/raw] the page was written successfully wit= hout that error. Terry Nair pointed out I was overlooking the javascript when using [raw][/r= aw] On Monday, October 7, 2019, 12:55:40 AM CDT, Stuart Tremain wrote: =20 =20 Hi Richard I am not sure if I have the scenarios correct here. 1) You create a new page by copying a template 2) You want [TEXT]name=3Drichard[/TEXT] in the new page (this is the bit th= at I am unsure of) If you want [TEXT]name=3Drichard[/TEXT] to appear in the saved version of t= he page you would need to do this [RAW][TEXT]name=3D[/RAW[name_to_save][RAW= ][/TEXT][/RAW] Doing it this way will ensure that [TEXT]name=3Drichard[/TEXT] is written (= saved) on the new page rather than being a value held in RAM and lost as so= on as the page is loaded. Kind regards Stuart TremainPharoah Lane SoftwareAUSTRALIAwebdna@plsoftware.com.au On 7 Oct 2019, at 01:28, Richard Kwasniewski wrote: I'm creating a a new html page from a form. The user inputs a "page_name" and a "name". I need this "name" to get passe= d into the new page made by copying a template using [copyfile] I need a text variable created on this new page[text]name=3DMelissa[/text](= Melissa is the name being passed via the form in this example) Possible? This is what I'm using for the copyfile command[copyfile from=3Dtemplate.ht= ml&to=3D../[lowercase][page_name][/lowercase].html] I have this in my template that is used to create the new page:[text]name= =3D[name][/text] [name] gets passed just fine from the and gets written into the database.BU= T the variable always is=C2=A0[text]name=3D[name][/text]on the new page cre= ated. This is all the code on the page that gets the input from the form: [append db=3Dpages.db][!] [/!]page_id=3D[page_id][!] [/!]&page_name=3D[url][page_name][/url][!] [/!]&name=3D[url][name][/url][!] [/!][!]&description=3D[url][description][/url][/!][!] [/!]&active=3DNo[!] [/!]&create_time=3D[time][!] [/!]&create_date=3D[date][!] [/!]&create_ipaddress=3D[ipaddress][!] [/!][/append] [copyfile from=3Dcompanion.html&to=3D../[lowercase][page_name][/lowercase].= html] Like always thanks for glancing at this. Richard ---------------------------------------------------------This message is se= nt to you because you are subscribed tothe mailing list talk@webdna.usTo un= subscribe, E-mail to: talk-leave@webdna.usarchives: http://www.webdna.us/pa= ge.dna?numero=3D55Bug Reporting: support@webdna.us ---------------------------------------------------------This message is se= nt to you because you are subscribed tothe mailing list talk@webdna.usTo un= subscribe, E-mail to: talk-leave@webdna.usarchives: http://www.webdna.us/pa= ge.dna?numero=3D55Bug Reporting: support@webdna.us =20 ------=_Part_2978911_1887828090.1570444912043 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I achieved everything that I= needed using [writefile]. 
[text] variable passed from the form into the new page succesfully etc.

I did things that way about 5-7 years ago and this time ar= ound I just thought [copyfile] was the way to go, but it didn't seem to be = after I located those old pages and looked them over.

And= yes I did have to sprinkle [raw][/raw] here and there within the html code= being written into a new file.

The last reference to the= an error I kept getting:
 = ; Error: Error: expected [/IF], but found [/writefile] instead[/writefile]<= /div>

Was being generated by the following javascript within th= e stuff being written to the new page, and not because I messed up some web= dna code:

   <!-- HTML5 shiv and R= espond.js IE8 support of HTML5 elements and media queries -->
=     <!--[if lt IE 9]>
    <script sr= c=3D"js/html5shiv.js"></script>
    <script= src=3D"js/respond.min.js"></script>
    <![endif]-->

I k= ept looking at webdna code thinking I messed something up and never looked = twice at that javascript thinking I needed to [raw][/raw] it.

Once I surrounded it with [raw][/raw] the page was written successfull= y without that error.

Terry Nair pointed out I was overlo= oking the javascript when using [raw][/raw]




=20
=20
On Monday, October 7, 2019, 12:55:40 AM CDT, Stuart Tre= main <webdna@plsoftware.com.au> wrote:


Hi Richard

I am not sure if I have the scenarios correct here.

1) You create a new page by copying a temp= late

2) You want [TEXT]name=3Drichard[= /TEXT] in the new page (this is the bit that I am unsure of)

If you want [TEXT]name=3Drichard[/TEXT] to appear in= the saved version of the page you would need to do this [RAW][TEXT]name=3D= [/RAW[name_to_save][RAW][/TEXT][/RAW]
= Doing it this way will ensure that [TEXT]name=3Drichard[/TEXT] is written (= saved) on the new page rather than being a value held in RAM and lost as so= on as the page is loaded.

Kind r= egards

Stuart Tremain
Pharoah Lane Software
= AUSTRALIA





On 7 Oct 2019, at 01:28, Ri= chard Kwasniewski <richiekwas@gmail.com> wrote:

I'm creating a a new= html page from a form.

The user inputs a "p= age_name" and a "name". I need this "name" to get passed into the new page = made by copying a template using [copyfile]

I need a text variable created on this new page
[text]name=3DMelissa[/text]
= (Melissa is the name being passed via the form in this example)


=
Possible?
This is what I'm using for the copyfile command
[copyfile from=3Dtemplate.html&to=3D../[lowercase][page_name][/= lowercase].html]

I have this in my template that is used to create the= new page:
[text]name=3D[name][/text]
<= br clear=3D"none" class=3D"yiv1682319431">
[name] gets passed just fine from the and gets written into the database.=
BUT the variable always is 
[text]name=3D[name][/text]
on the new page created.
=
This is all the code on the page that gets the input from the form:

[append db=3Dpages.db][!]
[/!]page_id=3D[page_id][!]
[/!]&page_name=3D[url][page_name][/url][!]
[/!]&name=3D[url][name][/url][!]
[/!][!]&description=3D[url][descr= iption][/url][/!][!]
[/!]&act= ive=3DNo[!]
[/!]&create_time= =3D[time][!]
[/!]&create_date= =3D[date][!]
[/!]&create_ipad= dress=3D[ipaddress][!]
[/!][/appe= nd]


[copyfile from=3Dc= ompanion.html&to=3D../[lowercase][page_name][/lowercase].html]

= Like always thanks for glancing at this.
=

Richard

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.w= ebdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.webdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us
--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.webdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us ------=_Part_2978911_1887828090.1570444912043-- . Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  2. Re: [WebDNA] Passing a text variable via copyfile (WebDNA Solutions 2019)
  3. Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  4. Re: [WebDNA] Passing a text variable via copyfile (Stuart Tremain 2019)
  5. RE: [BULK] Re: [WebDNA] Passing a text variable via copyfile ("Terry Nair" 2019)
  6. [BULK] Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  7. RE: [WebDNA] Passing a text variable via copyfile ("Terry Nair" 2019)
  8. Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  9. Re: [WebDNA] Passing a text variable via copyfile (WebDNA Solutions 2019)
  10. Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  11. RE: [WebDNA] Passing a text variable via copyfile ("Scott @ Itsula" 2019)
  12. Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  13. RE: [WebDNA] Passing a text variable via copyfile ("Scott @ Itsula" 2019)
  14. Re: [WebDNA] Passing a text variable via copyfile (Rich Kwas 2019)
  15. Re: [WebDNA] Passing a text variable via copyfile (WebDNA Solutions 2019)
  16. [WebDNA] Passing a text variable via copyfile (Richard Kwasniewski 2019)
2534 ------=_Part_2978911_1887828090.1570444912043 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable I achieved everything that I needed using [writefile].=C2=A0[text] variabl= e passed from the form into the new page succesfully etc. I did things that way about 5-7 years ago and this time around I just thoug= ht [copyfile] was the way to go, but it didn't seem to be after I located t= hose old pages and looked them over. And yes I did have to sprinkle [raw][/raw] here and there within the html c= ode being written into a new file. The last reference to the an error I kept getting:=C2=A0 Error: Error: expe= cted [/IF], but found [/writefile] instead[/writefile] Was being generated by the following javascript within the stuff being writ= ten to the new page, and not because I messed up some webdna code: =C2=A0 =C2=A0=C2=A0 =C2=A0 I kept looking at webdna code thinking I messed something up and never look= ed twice at that javascript thinking I needed to [raw][/raw] it. Once I surrounded it with [raw][/raw] the page was written successfully wit= hout that error. Terry Nair pointed out I was overlooking the javascript when using [raw][/r= aw] On Monday, October 7, 2019, 12:55:40 AM CDT, Stuart Tremain wrote: =20 =20 Hi Richard I am not sure if I have the scenarios correct here. 1) You create a new page by copying a template 2) You want [text]name=3Drichard[/TEXT] in the new page (this is the bit th= at I am unsure of) If you want [text]name=3Drichard[/TEXT] to appear in the saved version of t= he page you would need to do this [raw][text]name=3D[/RAW[name_to_save][RAW= ][/TEXT][/RAW] Doing it this way will ensure that [text]name=3Drichard[/TEXT] is written (= saved) on the new page rather than being a value held in RAM and lost as so= on as the page is loaded. Kind regards Stuart TremainPharoah Lane SoftwareAUSTRALIAwebdna@plsoftware.com.au On 7 Oct 2019, at 01:28, Richard Kwasniewski wrote: I'm creating a a new html page from a form. The user inputs a "page_name" and a "name". I need this "name" to get passe= d into the new page made by copying a template using [copyfile] I need a text variable created on this new page[text]name=3DMelissa[/text](= Melissa is the name being passed via the form in this example) Possible? This is what I'm using for the copyfile command[copyfile from=3Dtemplate.ht= ml&to=3D../[lowercase][page_name][/lowercase].html] I have this in my template that is used to create the new page:[text]name= =3D[name][/text] [name] gets passed just fine from the and gets written into the database.BU= T the variable always is=C2=A0[text]name=3D[name][/text]on the new page cre= ated. This is all the code on the page that gets the input from the form: [append db=3Dpages.db][!] [/!]page_id=3D[page_id][!] [/!]&page_name=3D[url][page_name][/url][!] [/!]&name=3D[url][name][/url][!] [/!][!]&description=3D[url][description][/url][/!][!] [/!]&active=3DNo[!] [/!]&create_time=3D[time][!] [/!]&create_date=3D[date][!] [/!]&create_ipaddress=3D[ipaddress][!] [/!][/append] [copyfile from=3Dcompanion.html&to=3D../[lowercase][page_name][/lowercase].= html] Like always thanks for glancing at this. Richard ---------------------------------------------------------This message is se= nt to you because you are subscribed tothe mailing list talk@webdna.usTo un= subscribe, E-mail to: talk-leave@webdna.usarchives: http://www.webdna.us/pa= ge.dna?numero=3D55Bug Reporting: support@webdna.us ---------------------------------------------------------This message is se= nt to you because you are subscribed tothe mailing list talk@webdna.usTo un= subscribe, E-mail to: talk-leave@webdna.usarchives: http://www.webdna.us/pa= ge.dna?numero=3D55Bug Reporting: support@webdna.us =20 ------=_Part_2978911_1887828090.1570444912043 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I achieved everything that I= needed using [writefile]
[text] variable passed from the form into the new page succesfully etc.

I did things that way about 5-7 years ago and this time ar= ound I just thought [copyfile] was the way to go, but it didn't seem to be = after I located those old pages and looked them over.

And= yes I did have to sprinkle [raw][/raw] here and there within the html code= being written into a new file.

The last reference to the= an error I kept getting:
 = ; Error: Error: expected [/IF], but found [/writefile] instead[/writefile]<= /div>

Was being generated by the following javascript within th= e stuff being written to the new page, and not because I messed up some web= dna code:

   <!-- HTML5 shiv and R= espond.js IE8 support of HTML5 elements and media queries -->
=     <!--[if lt IE 9]>
    <script sr= c=3D"js/html5shiv.js"></script>
    <script= src=3D"js/respond.min.js"></script>
    <![endif]-->

I k= ept looking at webdna code thinking I messed something up and never looked = twice at that javascript thinking I needed to [raw][/raw] it.

Once I surrounded it with [raw][/raw] the page was written successfull= y without that error.

Terry Nair pointed out I was overlo= oking the javascript when using [raw][/raw]




=20
=20
On Monday, October 7, 2019, 12:55:40 AM CDT, Stuart Tre= main <webdna@plsoftware.com.au> wrote:


Hi Richard

I am not sure if I have the scenarios correct here.

1) You create a new page by copying a temp= late

2) You want [text]name=3Drichard[= /TEXT] in the new page (this is the bit that I am unsure of)

If you want [text]name=3Drichard[/TEXT] to appear in= the saved version of the page you would need to do this [raw][text]name=3D= [/RAW[name_to_save][raw][/TEXT][/RAW]
= Doing it this way will ensure that [text]name=3Drichard[/TEXT] is written (= saved) on the new page rather than being a value held in RAM and lost as so= on as the page is loaded.

Kind r= egards

Stuart Tremain
Pharoah Lane Software
= AUSTRALIA





On 7 Oct 2019, at 01:28, Ri= chard Kwasniewski <richiekwas@gmail.com> wrote:

I'm creating a a new= html page from a form.

The user inputs a "p= age_name" and a "name". I need this "name" to get passed into the new page = made by copying a template using [copyfile]

I need a text variable created on this new page
[text]name=3DMelissa[/text]
= (Melissa is the name being passed via the form in this example)


=
Possible?
This is what I'm using for the copyfile command
[copyfile from=3Dtemplate.html&to=3D../[lowercase][page_name][/= lowercase].html]

I have this in my template that is used to create the= new page:
[text]name=3D[name][/text]
<= br clear=3D"none" class=3D"yiv1682319431">
[name] gets passed just fine from the and gets written into the database.=
BUT the variable always is 
[text]name=3D[name][/text]
on the new page created.
=
This is all the code on the page that gets the input from the form:

[append db=3Dpages.db][!]
[/!]page_id=3D[page_id][!]
[/!]&page_name=3D[url][page_name][/url][!]
[/!]&name=3D[url][name][/url][!]
[/!][!]&description=3D[url][descr= iption][/url][/!][!]
[/!]&act= ive=3DNo[!]
[/!]&create_time= =3D[time][!]
[/!]&create_date= =3D[date][!]
[/!]&create_ipad= dress=3D[ipaddress][!]
[/!][/appe= nd]


[copyfile from=3Dc= ompanion.html&to=3D../[lowercase][page_name][/lowercase].html]

= Like always thanks for glancing at this.
=

Richard

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.w= ebdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.webdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us
--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list talk@webdna.us To unsubscribe, E-mail to: talk-leave@webdna.us archives: http://www.webdna.us/page.dna?numero=3D55 Bug Reporting: support@webdna.us ------=_Part_2978911_1887828090.1570444912043-- . Rich Kwas

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Notepad problems - SOLVED! (1998) Problems with large number of items in a cart. (1998) [OT] Google Info (2004) RE: Cart Template (1997) no global [username] or [password] displayed ... (1997) Bug or syntax error on my part? (1997) Math with Time (1997) Cart doesn't interpret tag! (1997) AutoCommit Preference? (1998) Some Questions (1997) multiple replace sku data (2003) Country & Ship-to address & other fields ? (1997) restart needed???? (1997) Another question (1997) WebCatalog-3.0800 on Mac OS X Server (2000) Images (2000) Help! WebCat2 bug (1997) how to do multiple prices/item? (1998) [delete] problem (1997) Formatting ModDate (2000)