Re: [WebDNA] Clean URLS job - will pay
This WebDNA talk-list message is from 2010
It keeps the original formatting.
numero = 104921
interpreted = N
texte = Page name will always be index.csn as that is the name of the template =not the url. If you need the value of the url, you will need to pass =that as a variable.=46rom memory [ThisURL] will also display index.csnRegardsStuart TremainIDFK Web DevelopmentsAUSTRALIAwebdna@idfk.com.auOn 03/03/2010, at 10:23 AM, Diane Blackmore (Cohesion) wrote:> Hi>=20> Back to this.... BTW you guys on the list are all awesome...>=20> Matthew - Can confirm that your method seems to best achieve what I'm =after,> and that mod_rewrite is working on the server. Problem is now as =follows;>=20> Using your exact rewrite rule below, the URL>=20> ../accommodation.csn?var1=3D1var&var2=3D2var&var3=3D3var>=20> Now successfully goes to the right place. The problem is that =according to> the WebDNA template (index.csn) that it's rewriting to, the variables =aren't> being carried over quite right....>=20> In the above example, the variables var1, var2, var3 are all OK so the> problem clearly isn't with the QSA string.>=20> The problem is that the pageName variable has become 'index' for some> reason... Perhaps getting this from some other part of the rule.>=20> Any ideas on this one?? If I can get this sorted I'll have the whole =thing> nailed.>=20>=20> Cheers,>=20>=20> on 16/2/10 11:07 AM, Matthew Bohne at matthew.bohne@benetela.com =wrote:>=20>> Should be able to do it with this. The [L] means it is the last rule>> parsed, and the [QSA] tells mod_rewrite to pass the query string =also.>>=20>>
>> RewriteEngine on>> RewriteRule ^([A-Za-z0-9_]+).csn?$ index.csn?pageName=3D$1 [L,QSA]>> >>=20>> That said, mod_rewrite is worth learning.>>=20>>=20>> Diane Blackmore wrote:>>> Hi>>>=20>>> I have a need for a solution to rewrite =96 either by mod_rewrite or>>> other =96 the following URL syntax;>>>=20>>> url needs to go from:>>>=20>>>=20>>> =http://launch72.cohesion.co.nz/online/index.csn?pageName=3Dadvertiser_vaca=ncie>>> s&var1=3Dvar1&var2=3Dvar2&var3=3Dvar3>>>=20>>> etc>>>=20>>> to>>>=20>>> =http://launch72.cohesion.co.nz/online/advertiser_vacancies.csn?var1=3Dvar1=&var>>> 2=3Dvar2&var3=3Dvar3>=20>>> etc>>>=20>>>=20>>> Happy to pay for this as a job, but its just not worth my learning>>> mod_rewrite for this one thing, and it=92s kinda advanced given I=92m =a>>> beginner at such things.>>>=20>>> You can contact me off list if you want to negotiate, otherwise if =you>>> look at the above and go =93oh for heaven=92s sake that=92s too =easy=94 and>>> jst want to answer it here and now for the greater good of the =WebDNA>>> community, knock your socks off.>>>=20>>>=20>>>=20>>> Regards,>>>=20>>>=20>>=20>> --------------------------------------------------------->> This message is sent to you because you are subscribed to>> the mailing list
.>> To unsubscribe, E-mail to: >> archives: http://mail.webdna.us/list/talk@webdna.us>> old archives: http://dev.webdna.us/TalkListArchive/>> Bug Reporting: =http://forum.webdna.us/eucabb.html?page=3Dtopics&category=3D288>>=20>>=20>=20>=20>=20>=20>=20> ---------------------------------------------------------> This message is sent to you because you are subscribed to> the mailing list .> To unsubscribe, E-mail to: > archives: http://mail.webdna.us/list/talk@webdna.us> old archives: http://dev.webdna.us/TalkListArchive/> Bug Reporting: =http://forum.webdna.us/eucabb.html?page=3Dtopics&category=3D288
Associated Messages, from the most recent to the oldest:
Page name will always be index.csn as that is the name of the template =not the url. If you need the value of the url, you will need to pass =that as a variable.=46rom memory [thisurl] will also display index.csnRegardsStuart TremainIDFK Web DevelopmentsAUSTRALIAwebdna@idfk.com.auOn 03/03/2010, at 10:23 AM, Diane Blackmore (Cohesion) wrote:> Hi>=20> Back to this.... BTW you guys on the list are all awesome...>=20> Matthew - Can confirm that your method seems to best achieve what I'm =after,> and that mod_rewrite is working on the server. Problem is now as =follows;>=20> Using your exact rewrite rule below, the URL>=20> ../accommodation.csn?var1=3D1var&var2=3D2var&var3=3D3var>=20> Now successfully goes to the right place. The problem is that =according to> the WebDNA template (index.csn) that it's rewriting to, the variables =aren't> being carried over quite right....>=20> In the above example, the variables var1, var2, var3 are all OK so the> problem clearly isn't with the QSA string.>=20> The problem is that the pageName variable has become 'index' for some> reason... Perhaps getting this from some other part of the rule.>=20> Any ideas on this one?? If I can get this sorted I'll have the whole =thing> nailed.>=20>=20> Cheers,>=20>=20> on 16/2/10 11:07 AM, Matthew Bohne at matthew.bohne@benetela.com =wrote:>=20>> Should be able to do it with this. The [L] means it is the last rule>> parsed, and the [QSA] tells mod_rewrite to pass the query string =also.>>=20>> >> RewriteEngine on>> RewriteRule ^([A-Za-z0-9_]+).csn?$ index.csn?pageName=3D$1 [L,QSA]>> >>=20>> That said, mod_rewrite is worth learning.>>=20>>=20>> Diane Blackmore wrote:>>> Hi>>>=20>>> I have a need for a solution to rewrite =96 either by mod_rewrite or>>> other =96 the following URL syntax;>>>=20>>> url needs to go from:>>>=20>>>=20>>> =http://launch72.cohesion.co.nz/online/index.csn?pageName=3Dadvertiser_vaca=ncie>>> s&var1=3Dvar1&var2=3Dvar2&var3=3Dvar3>>>=20>>> etc>>>=20>>> to>>>=20>>> =http://launch72.cohesion.co.nz/online/advertiser_vacancies.csn?var1=3Dvar1=&var>>> 2=3Dvar2&var3=3Dvar3>=20>>> etc>>>=20>>>=20>>> Happy to pay for this as a job, but its just not worth my learning>>> mod_rewrite for this one thing, and it=92s kinda advanced given I=92m =a>>> beginner at such things.>>>=20>>> You can contact me off list if you want to negotiate, otherwise if =you>>> look at the above and go =93oh for heaven=92s sake that=92s too =easy=94 and>>> jst want to answer it here and now for the greater good of the =WebDNA>>> community, knock your socks off.>>>=20>>>=20>>>=20>>> Regards,>>>=20>>>=20>>=20>> --------------------------------------------------------->> This message is sent to you because you are subscribed to>> the mailing list .>> To unsubscribe, E-mail to: >> archives: http://mail.webdna.us/list/talk@webdna.us>> old archives: http://dev.webdna.us/TalkListArchive/>> Bug Reporting: =http://forum.webdna.us/eucabb.html?page=3Dtopics&category=3D288>>=20>>=20>=20>=20>=20>=20>=20> ---------------------------------------------------------> This message is sent to you because you are subscribed to> the mailing list .> To unsubscribe, E-mail to: > archives: http://mail.webdna.us/list/talk@webdna.us> old archives: http://dev.webdna.us/TalkListArchive/> Bug Reporting: =http://forum.webdna.us/eucabb.html?page=3Dtopics&category=3D288
Stuart Tremain
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:
PCS Frames (1997)
Encrypted items in DB (2001)
Help! WebCat2 bug (1997)
Running _every_ page through WebCat ? (1997)
Sorting problem (2002)
WebCatalog for guestbook ? (1997)
WebCat editing, SiteGuard & SiteEdit (1997)
Storebuilder questions (2003)
WebCat name recognition (1998)
search for all (1998)
WCS Newbie question (1997)
WebCatb15 Mac CGI -- [purchase] (1997)
textarea inputs and returns (1999)
More DateMath problems (1997)
PCS Frames (1997)
Newbie from and old bee (1997)
refreshing IE with posted .tmpl (1997)
Feature Request: DB Field manipulation (1998)
[OT] Connect to MySQL (2004)
WebDNA for Dummies (2004)