viktor
|
| Posted: 09/14/2004, 6:51 AM |
|
I am using CodeCharge Studio
Is there any easier way with CSS to do 'clean URL' or is it all bound to server configuration?
Thanks
|
|
|
 |
Nicole
Posts: 586
|
| Posted: 09/17/2004, 1:59 AM |
|
Viktor,
Can you clarify what you mean by "Clean URL"?
_________________
Regards,
Nicole |
 |
 |
zeuch
Posts: 25
|
| Posted: 09/17/2004, 3:46 AM |
|
Hi, viktor
do you that to cut out whole the variables of the URL?
You can create a link for the same page. In the link properities you change to "None" in "Preserve Parameters".
Regards,
Matheus
_________________
Matheus Zeuch |
 |
 |
viktor
|
| Posted: 09/23/2004, 5:05 AM |
|
Quote zeuch:
Hi, viktor
do you that to cut out whole the variables of the URL?
You can create a link for the same page. In the link properities you change to "None" in "Preserve Parameters".
Regards,
Matheus
i mean cases when i have a page with url /product.php?id=5...
the id is to be passed to the page product.php so that Grid could be filtered using URL.
My ideas is to find an easy way to turn "/product.php?id=5" into something more meangfull like "/product_5.php"...
I have heard there some Apache vaiable / settings should be set.
Can anybody please advise?
|
|
|
 |
Karsten
Posts: 57
|
| Posted: 09/27/2004, 5:01 PM |
|
hi viktor,
first of all, why do you need this? for what is it really?
you wil never be able to change ?id=5
into product_5.php without extensive coding and/or hacking the apache sourcecode and recompile it 
if you want to "hide" your data, i use to key/unkey the urlvariables with a function i wrote explicit for that you also could use the session array, there are many ways, if you really need to do that.
but however, i dont think you really need to change a url into something else, the user is not interested what the url looks like , he wants functionality i think.
sers
Karsten from germany
_________________
If one gives up, he told himself he failed. |
 |
 |
Geert van der Ploeg
|
| Posted: 09/29/2004, 5:22 AM |
|
"viktor" <viktor@forum.codecharge> wrote in message
news:54152bc1605fc9@news.codecharge.com...
> i mean cases when i have a page with url /product.php?id=5...
>
> the id is to be passed to the page product.php so that Grid could be
filtered
> using URL.
>
> My ideas is to find an easy way to turn "/product.php?id=5" into something
more
> meangfull like "/product_5.php"...
>
> I have heard there some Apache vaiable / settings should be set.
>
> Can anybody please advise?
With Apache you can use the directive <Files> for this, in .htaccess
Example:
[geertweb@genesis htdocs]$ cat .htaccess
<Files photos>
ForceType application/x-httpd-php
AcceptPathInfo on
</Files>
That will cause all requests beginning with 'photos' to be forwarded to the
file called 'photos'.
In the file photos (a php-script) you can then parse the whole URL into
parameters.
I've done this as follows:
Links in my pages look like this: /photos/holiday/312/thumbnail.html
which gets parsed into:
collection = holiday
photoid = 312
template = thumbnail.html
Regards,
Geert van der Ploeg
|
|
|
 |
Karsten
Posts: 57
|
| Posted: 09/29/2004, 3:16 PM |
|
hi Geert,
do you think this is "nice style"?
_________________
If one gives up, he told himself he failed. |
 |
 |
GeorgeS
Posts: 206
|
| Posted: 09/29/2004, 11:24 PM |
|
Hi Karsten,
What would you do in terms of SEO if your pages have a lot of params in a querystrings?
Google just began listing pages that have no more that 2 parameters.
Many webmasters do this mostly for getting many of the dynamic pages with more than 2 parameters listied by search engines as separate pages.
What are your SEO techniques?
_________________
GeorgeS |
 |
 |
hussa
Posts: 1
|
| Posted: 09/30/2004, 12:01 AM |
|
Hi ,
why dont you use the mod_rewrite module of the apache
you may have a look at http://www.webmaster-toolkit.com/mod_rewrite-rewriterule-generator.shtml
For generall Information:
"RTFM" @ http://httpd.apache.org/docs/mod/mod_rewrite.html
Sorry i dont have more time für es longer Answer - will have a look this evening
Hans
|
 |
 |
Karsten
Posts: 57
|
| Posted: 10/02/2004, 2:45 PM |
|
Hi GeorgS
I personaly dont "Spam" searchengines, in my opinion if a site is good and the public need/want it it will go its deserved way.
however, if one needs to have no params in url he could
use a global array and put all params there CCS for this has the "session" source/target property.For example
in common.php define an session array and in your application always use this array to save/get data from site to site. its not too much work with CCS because of the "session" property (just use session variable[x] instead of URL variablename) ok it may be a bit more work and unusable for the not so expirienced programmer/CCS user but what you earn for this bit more work is absolute no URL parameters.
Karsten from Germany
sers
_________________
If one gives up, he told himself he failed. |
 |
 |
viktor
|
| Posted: 10/08/2004, 6:16 AM |
|
Quote hussa:
Many thanks Hans for the link!
The generator works perfect and saved me some weeks of learning the Re-write syntax.
I've already spend some 3-4 days trying to make it working using .htaccess and now it works just like that!
Thanks to all for useful discussions.
|
|
|
 |
viktor
|
| Posted: 10/08/2004, 6:51 AM |
|
Last question related to clean URL
When I have clean URL. There are some links on the page. The page was generated by CCS.
The links take as a "base" this "clean url" and hence I get an error.
Is there any way of "redirection"
i.e.: http://www.activelife.kiev.ua/facility/facilities_id_50 page is clean URL for http://www.activelife.kiev.ua/facility/facilities_id_5 for http://www.activelife.kiev.ua/facility.php?facilities_id=50
so all links generated by CCS "crashes" when in clean URL mode?
Any suggestion?
Thanks
|
|
|
 |
viktor
|
| Posted: 10/08/2004, 7:08 AM |
|
well. I hacked it: Just using 'Convert URL To' and choose 'Absolute'
Now last question:
How do I make links to those "clean" URLs?
I mean all the links generated by CCS are: page.php?parameter=value
How do I make it by default to point to page/parameter/value?
Any ideas except global change?
Thanks
|
|
|
 |
elias
|
| Posted: 10/08/2004, 3:56 PM |
|
viktor,
try using $myGrid->myLinkControl->SetLink("page.php") in BeforeShow event for myLinkControl or BeforeShowRow event for the grid
for example:
$myGrid->myLinkControl->SetLink("page.php/Facility_id/" . $myGrid->Facility_id->GetValue())
will give you a link:
page.php/Facility_id/50
is it what you are trying to do?
best regards,
eli
______________________________________________________
question to Karsten about spamming:
If someone will change his URLs from "page.php?facility=2& room=4" to "page/2/4" this will be spamming?
So, making URLs "Search Engine - friendly" is not a good thing...
|
|
|
 |
viktor
|
| Posted: 10/11/2004, 11:04 AM |
|
Quote elias:
viktor,
try using $myGrid->myLinkControl->SetLink("page.php") in BeforeShow event for myLinkControl or BeforeShowRow event for the grid
for example:
$myGrid->myLinkControl->SetLink("page.php/Facility_id/" . $myGrid->Facility_id->GetValue())
Thanks for the tip!
It is now in my bookmarks!
|
|
|
 |