Results 1 to 7 of 7
  1. #1
    Newbie
    Join Date
    February 20th, 2005
    Posts
    14
    Mod Rewrite and Dynamic Titles
    I was reading in the forums about mod rewrite and dynamic titles. I went to C3scripts and printed the Documentation on Mod_rewrite. My question is:
    Do I move the .htaccess from the cgi-bin to the root directory and add the additional lines, or do I leave the .htaccess in cgi-bin and create an additional .htaccess file at the root directory? And other than URL's that I redirect will all the other requests go to the cgi-bin as always?

    And how or where do I find documentation about dynamic titles or how to use them?


    Sorry, this sounds so dumb but if mod_rewrite really looks like html, I'd be dumb not to use it.

    Thanks,
    Barbara

  2. #2
    pph Expert! Gordon's Avatar
    Join Date
    January 18th, 2005
    Location
    Edmonton Canada
    Posts
    5,781
    I put my .htaccess in the root directory. I dont know what your cgi-bin .htaccess does I asume it is just to ban people from it, if so leave that one in as it is and create new one for the mod-rewrite and place it in the root directory. I think this will work.

    I don't know enough about it to answer this question
    And other than URL's that I redirect will all the other requests go to the cgi-bin as always?
    but I would imagine if they are not included in your re-write they will.
    One day parasites and their ilk will be made illegal, I bet a few Lawyers will be pissed off when the day comes.
    Mr. Spitzer is fetching it nearer

    YouTrek

  3. #3
    ABW Ambassador cusimano's Avatar
    Join Date
    January 18th, 2005
    Location
    Toronto, Canada
    Posts
    1,369
    I assume that you are asking about mod_rewrite .htaccess with regards to Associate Engine. See the Associate Engine Virtual Directory / mod_rewrite documentation.

    Create the .htaccess file in your root directory (or add lines to your existing .htaccess file in your root directory).

    The Associate Engine related lines that you put in your .htaccess file only match the virtual directory that you specify (e.g.: /amazon). All other URL's are not affected by the Associate Engine related lines.

    Associate Engine does not require any .htaccess file in your cgi-bin directory. If you have one there for some other reason, you don't need to change it.

    Associate Engine automatically generates the value in the <TITLE> tag to be relevant (assuming that you're using the templates supplied with Associate Engine or you use <TITLE>{title}</TITLE> in your own custom template).

    Yours truly,
    Cusimano.Com Corporation
    per: David Cusimano

  4. #4
    Newbie
    Join Date
    February 20th, 2005
    Posts
    14
    Thanks for your reply,,,just to make sure I'm on the way
    After I submitted the post, I realized that I didn't tell what script. I have AE installed on several websites and it's terrific. The web is a learning process. I just found the posts on mod-rewrite and thought I would try it on one of the smaller sites to begin with. The AE install had an .htaccess file that resides in the cgi-bin, and I just looked and there isn't one in the root directory. So, I just create a new .htaccess file, and make the modification to ae.ini and upload them, and the mod-rewrite feature will work when I change the URL's?

    And I think my default template already uses what you may be calling the dynamic title function. When I display something that is in the cgi-bin it shows the product categorie and my website name in the page title. Is that it. So, SE's will crawl these pages even though they have no Meta Desc. or Meta Keyword Tags?

    I checked to make sure my host does support mod_rewrite and they do. What a find, if this will get the search engines interested.

    Thanks for your reply.

    Barbara

  5. #5
    Newbie
    Join Date
    February 20th, 2005
    Posts
    14
    Just wanted to come back and say thanks!
    Thanks so much, I got mod_rewrite working on one of my websites and all the links on my home page changed and all is working well. I have added
    about "30 new pages" LOL. Who would have thought it would be so easy!

    Barbara

  6. #6
    Newbie
    Join Date
    February 20th, 2005
    Posts
    14
    Moc_rewrite and the script parameter?
    In AE, I use the script parameters to show the Top 10 best sellers. Is there a way to change this to look like it is html?

    <SCRIPT TYPE="text/JavaScript" SRC="http://www.yourdomain.com/cgi-bin/ae.pl?script&type=bestsellers&mode=baby&grid=c:3,r:3,n,m"></SCRIPT>

    Thanks,
    Barbara

  7. #7
    ABW Ambassador cusimano's Avatar
    Join Date
    January 18th, 2005
    Location
    Toronto, Canada
    Posts
    1,369
    <script> tags are ignored by search engines since search engines cannot run javascript. You can use a Server-Side-Include (SSI). With SSI, the output of the SSI is inserted into the webpage at the server end and the entire (substituted) webpage is what users/search engines see.

    Use:

    <!--#include virtual="/cgi-bin/ae.pl?ssi&type=best&mode=baby&grid=c:3,r:3,n,m"-->

    (in this post the above line may have wrapped onto two lines; it's supposed to be one long line).

    The parameter called "ssi" is used to tell ae.pl that it is being called from an SSI statement. (You would use the parameter called "script" when calling ae.pl from a <script> tag).

    The general format of the SSI is:

    <!--#include virtual="/cgi-bin/ae.pl?ssi&OTHER_AE_PARAMETERS"-->

    (change /cgi-bin/ae.pl if your ae.pl is at a different URL)

    You can use SSI in your AE templates. If you use in your static .html files, your server may or may not process the SSI's depending upon the configuration of your server. Some servers only process SSI's if the filename ends with .shtml rather than .html; try .html and if it doesn't work then try .shtml filename. Your hosting company can configure the server to process SSI's in .html files too.

    Yours truly,
    Cusimano.Com Corporation
    per: David Cusimano

  8. Newsletter Signup

+ Reply to Thread

Similar Threads

  1. Help Mod rewrite
    By womanht in forum Programming / Datafeeds / Tools
    Replies: 4
    Last Post: April 10th, 2007, 10:01 PM
  2. dyse mod-rewrite & FrontPage
    By traffic-tart in forum Cusimano.com Scripts
    Replies: 1
    Last Post: August 21st, 2005, 02:27 PM
  3. mod rewrite - I just don't get it
    By tamborinegal in forum Programming / Datafeeds / Tools
    Replies: 12
    Last Post: April 20th, 2004, 06:59 AM
  4. Mod Rewrite Question
    By swampy_webber in forum Programming / Datafeeds / Tools
    Replies: 2
    Last Post: January 13th, 2004, 04:39 PM
  5. Anyone good with Mod Rewrite?
    By TJ in forum Programming / Datafeeds / Tools
    Replies: 7
    Last Post: November 22nd, 2003, 09:16 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •