SitePoint Sponsor

User Tag List

Results 1 to 17 of 17
  1. #1
    SitePoint Enthusiast
    Join Date
    Jun 2006
    Posts
    93
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    is it possible to write php/mysql site to CD?

    Hi,

    I have been asked to create some temporary sites (online for 12 months) that require a CMS. I would normally deploy a CMS using PHP/MYSQL, but i've also been asked if they can have the websites on a disc after the hosting expires so i wonder if there is some software that would allow me to write all files to the disc while also installing some server technology on the clients PC in order for the sites to run?

    If this is not possible, what are the alternatives?

    Thanks for any help

    G

  2. #2
    Programming Team silver trophybronze trophy
    Mittineague's Avatar
    Join Date
    Jul 2005
    Location
    West Springfield, Massachusetts
    Posts
    17,169
    Mentioned
    190 Post(s)
    Tagged
    2 Thread(s)
    Are you sure they don't just mean a copy of the files? Having a clone of the site that runs on a CD is a whole other thing. You might be able to get it to work for a particular setup, but a desktop app isn't a website. If it's a small site you might be able to save all the pages as HTML and they could run it in a browser that way. But for any dynamic PHP/MySQL stuff, they need the engines.

  3. #3
    SitePoint Wizard
    Join Date
    Jul 2003
    Location
    Kent
    Posts
    1,921
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    http://usbwebserver.com/download.php

    push it through google to translate.

    You build it on your own pc using this as the test server, then zip the entire usbwebserver folder and send it to them They unzip it, start the server (zero configuration) and use localhost to view their files. I was using it last week to build a system. Just note the bit about minirelay giving false anti-virus warnings - I've had them too, and try the version without minirelay as available from the site.

    Zip prevents a cd copy becoming read only when copied to their PC.

  4. #4
    SitePoint Member
    Join Date
    Jan 2010
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I've XAMPP before for that very purpose. I like that it already has phpmyadmin installed. It's meant to be used as a portable install.

    Do a google search for XAMPP. (I'd give a link, but I just joined.)

  5. #5
    SitePoint Enthusiast
    Join Date
    Jun 2006
    Posts
    93
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi

    Thanks for the replies so far.
    I don't want the client to be installing extra software, it has to be something that opens up in their browser on their computer.
    I think the php/mysql is not going to work.
    What about if it was just html files and xml based cms? That would work wouldn't it?
    Anyone know of an xml based cms that might work?

    Thanks for your help

  6. #6
    SitePoint Wizard
    Join Date
    Jul 2003
    Location
    Kent
    Posts
    1,921
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    If you put an unzipped copy of the entire folder on a cd, they just start the server from the cd and view in their browser.
    Or as the name suggests, give them it all on a small usb drive.

    The point of usbwebserver (and related portable servers) is that you DON'T install it, you just copy the entire folder and run it. From a CD they can't edit it of course.

  7. #7
    SitePoint Enthusiast
    Join Date
    Jun 2006
    Posts
    93
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi Dr John,

    Oh right...in that case it sounds just what i'm after. I did go to the website but wasn't sure if there was a MAC version do you know if it's PC only?
    I have a pc too so will use it in that if it is...just prefer working on the mac that's all.

    Hold on does this mean i can build the website, host it so the client can make their updates and after the 12 months are up package the website in it's entirety via usbwebserver?

    Thanks for the info.

  8. #8
    SitePoint Wizard
    Join Date
    Jul 2003
    Location
    Kent
    Posts
    1,921
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by geronimo171 View Post
    Hi Dr John,

    Oh right...in that case it sounds just what i'm after. I did go to the website but wasn't sure if there was a MAC version do you know if it's PC only?
    I have a pc too so will use it in that if it is...just prefer working on the mac that's all.

    Hold on does this mean i can build the website, host it so the client can make their updates and after the 12 months are up package the website in it's entirety via usbwebserver?

    Thanks for the info.
    No idea about the Mac bit, but I'm using it on a PC, so I too can give a little database app to one of my clients.

    Re. your hold on - the answer is yes. Copy all the online files and folders, and the database tables of course. The tables would need a database dump with create and data, then just run the sql through phpMyAdmin (in the system as well!) and check the DB connection (location, username etc) and it should work.

    If you were even sneakier, you'd remove phpMyAdmin from the folders you passed to the client, so they can only use your web interface.

  9. #9
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,580
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    You really don't want to be sending the MySQL server to someone in any form. That makes you a distributor of the code and binds you to the terms of the GPL license unless you purchase a commercial license from Sun. Bundle too tightly and you can end up covering the clients' code under GPL as well (it's a quite infectious license!).

  10. #10
    SitePoint Enthusiast
    Join Date
    Jun 2006
    Posts
    93
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Dan - I had thought whether this might be an issue and will have to look into a little further.

    Dr John - Thanks for clarifying that for me. I wonder if i might be able to contact you for assistance should i have any issues with the software? I probably won't be trying it out for a few weeks while i explore other options.

    Thanks again for all replies.

  11. #11
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,633
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    @Dan: very good point.

    Comedy option: roll your own linux livecd which boots a server running your app.

  12. #12
    SitePoint Enthusiast freezea's Avatar
    Join Date
    Apr 2009
    Posts
    38
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I highly doubt that it's possible. php and mysql both require a web server running and a web server is going to require an OS.
    RAQ Report: Web-based Excel-like Java reporting tool.

  13. #13
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,580
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Ya know, if all they want is a copy of content sites on a *disc* after it's taken offline, then why not download a static version of the site for that purpose only? You can get a 'website downloader' easily enough, or if there are only a few pages, just right click and save them from a web browser. As long as you're not hard coding links with full domains, the site will still work as static HTML files. You can still put the source code on the disc if they want to be able to access it, but they'll have to put that on a hosting account somewhere to edit it.

    If they just want an archive of their content then distributing live web and database servers on a disc and trying to get that to play well with everyone's PC is really overkill. It's got a 50/50 chance of failing depending on whether the version of Windows the end user has installed automatically installed IIS, which would've bound port 80 and prevent the web server you put on the disc from starting.

  14. #14
    SitePoint Enthusiast
    Join Date
    Jun 2006
    Posts
    93
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi Dan,
    A 'Website Downloader' is what i've found and it seems to work a treat.
    Offline Explorer Pro is a Windows only app (would prefer mac) but converts all files to html and runs in a browser with file structure intact from a cd.
    I didn't know such software existed but thanks for mentioning it in your last post.

    Thanks also to all other responses.

  15. #15
    SitePoint Wizard
    Join Date
    Jul 2003
    Location
    Kent
    Posts
    1,921
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Dan Grossman View Post
    Ya know, if all they want is a copy of content sites on a *disc* after it's taken offline, then why not download a static version of the site for that purpose only? You can get a 'website downloader' easily enough, or if there are only a few pages, just right click and save them from a web browser. As long as you're not hard coding links with full domains, the site will still work as static HTML files. You can still put the source code on the disc if they want to be able to access it, but they'll have to put that on a hosting account somewhere to edit it.

    If they just want an archive of their content then distributing live web and database servers on a disc and trying to get that to play well with everyone's PC is really overkill. It's got a 50/50 chance of failing depending on whether the version of Windows the end user has installed automatically installed IIS, which would've bound port 80 and prevent the web server you put on the disc from starting.
    USBwebserver uses port 8080
    I've had XAMPP and USBWebserver running simultaneously on the same laptop (Vista), as two different localhosts, then copied the usbWS folder to a four year old 256MB usb drive and connected that to my XP Pro desktop and it ran from there okay. XP Pro did have IIS installed as well, but I don't play with that.

    As for a static copy, the original post said CMS, PHP, MySQL, so I provided a simple (very simple!) solution to the question asked.

  16. #16
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,633
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    Or, that other port most people put their alternate web servers on . . .

  17. #17
    From space with love silver trophy
    SpacePhoenix's Avatar
    Join Date
    May 2007
    Location
    Poole, UK
    Posts
    5,025
    Mentioned
    103 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Dr John View Post
    USBwebserver uses port 8080
    I've had XAMPP and USBWebserver running simultaneously on the same laptop (Vista), as two different localhosts, then copied the usbWS folder to a four year old 256MB usb drive and connected that to my XP Pro desktop and it ran from there okay. XP Pro did have IIS installed as well, but I don't play with that.

    As for a static copy, the original post said CMS, PHP, MySQL, so I provided a simple (very simple!) solution to the question asked.
    USBwebserver or XAMP sound like the best two options for the OP. Possibly with XAMP as the main one and USBwebserver for testing different combinations of PHP, MySQL and Apache without breaking XAMP.
    Community Team Advisor
    Forum Guidelines: Posting FAQ Signatures FAQ Self Promotion FAQ
    Help the Mods: What's Fluff? Report Fluff/Spam to a Moderator


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
  •