SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Addict limepickle's Avatar
    Join Date
    Jan 2006
    Location
    Aldridge UK
    Posts
    216
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Support for .cgi files in Dreamweaver 8

    Does anyone know how I can fix this problem which has bugged me for nigh on a year now..

    I primarily use DW to maintain all the company sites with, as I like its FTP functionality and integration with FW etc. I also happen to think that as an editor its the bees knees. However, a LOT of legacy sites that I have to support contain perl cgi files.
    I have found the extension for .pl support and I now have coloured perl code, but the perl dw extension does not support .cgi files, so none of those have code colouring and its a royal pain in the *** to have to keep reverting to homesite & cute ftp all the time.

    Please oh please can someone tell me how to either edit the perl dw extension to include .cgi files, or something to that effect? Thanks!

  2. #2
    code ninja hamstu's Avatar
    Join Date
    Nov 2002
    Location
    Montréal, Canada
    Posts
    375
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I was able to get DW to open cgi files by adding the following line to the Extensions.txt:
    C:\Documents and Settings\{user}\Application Data\Macromedia\Dreamweaver 8\Configuration\Extensions.txt
    Code:
    CGI:CGI Files
    Be sure to restart DW.

    If you want it to highlight the code, you'll have to look into the CodeColoring files:
    C:\Documents and Settings\{user}\Application Data\Macromedia\Dreamweaver 8\Configuration\CodeColoring\CodeColoring.xml

  3. #3
    SitePoint Addict limepickle's Avatar
    Join Date
    Jan 2006
    Location
    Aldridge UK
    Posts
    216
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ah hah! Thanks, I can get them to open ok, but I was looking at the codecoloring files in the 'program files', not the 'documents & settings',

    I'll let you know how I get on

  4. #4
    SitePoint Addict limepickle's Avatar
    Join Date
    Jan 2006
    Location
    Aldridge UK
    Posts
    216
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok, for future reference heres what I did:

    Installed the perl support extension from the Dreamweaver exchange.

    Go to:
    C:\Documents and Settings\{your name}\Application Data\Macromedia\Dreamweaver 8\Configuration\DocumentTypes and open the PerlDocumentType.xml file.

    Add cgi to the following attributes like so:

    Code:
    winfileextension="pl,pm,cgi"
    
    macfileextension="pl,pm,cgi"
    Restart DW and there you go. I can't believe nobody has ever documented this before now!

  5. #5
    SitePoint Member
    Join Date
    Apr 2005
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hello,
    I noticed that the above posts refer to doing this in Dreamweaver 8 and 9. However, after acquistion of Macromedia by Adobe, some path changes and filename changes happened. So, for DW CS4 (and possible CS3 too), here is the exact workaround:

    Note: change 'user' mentioned below to your exact username in XP:

    CHANGE 1:
    Path: C:\Documents and Settings\user\Application Data\Adobe\Dreamweaver CS4\en_US\Configuration\DocumentTypes
    File: PerlDocumentType.xml

    CHANGE
    winfileextension="pl,pm" macfileextension="pl,pm"
    TO
    winfileextension="pl,pm,cgi" macfileextension="pl,pm,cgi"


    CHANGE 2:
    Path: C:\Documents and Settings\user\Application Data\Adobe\Dreamweaver CS4\en_US\Configuration\Extensions
    File: PerlSupport.mxi

    CHANGE
    <extension-insert extension="PL,PM" description="Perl files" />
    TO
    <extension-insert extension="CGI,PL,PM" description="Perl files" />


Bookmarks

Posting Permissions

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