Offline Web Page Development - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Offline Web Page Development

I am NOT a great web designer. I dont want to be. I tinker enough to make it look good though. Here's my problem. I do a lot of work at home and I do not have internet on my computer. I host my images on a web server. I would like to be able to develop on that home computer. Is there a way to make my computer think some folder with my pictures in it is www.whatever.com/images? I know I can just change the code to look for the file , but I do these for auctions on ebay, and I do an awful lot of them and the potential for error would be high. I get around it by just not seeing the pictures when I develop it and testing it later. Very time consuming.

Is there anything i can do? I'm more interested in if it can even be done now, than actually doing it.

Oh, I have downloded windows web servers but the closest i could get was to assign an ip address to a location on my drive. I dont want that.

Thank you geniouses!
Ken
«1

Comments

  • treshrtreshr Posts: 326Member
    If I understand you right you want to develop your website on your home computer and use images in your offline website.
    That's all possible and if your connected on the net when you're developing you can just use the URL to get the images you don't have on your harddisk at home.

    If you have an image on your home computer just use this:
    [code]
    image
    [/code]

    If you have an image an a remote computer just use this:
    [code]
    image
    [/code]

    Hope this helps you out.

    --=][tReShR][=--

  • kjmorfordkjmorford Posts: 4Member
    That's close! But no. I understand about using an image on my hard drive and the code difference for that. I want to develop the page(Ebay auction Ads) on a computer that is NOT on the internet with the same code it will have on ebay. If I dont have to change the code when it goes live , then my test will be valid. If I do have to change it, then it opens the door for all kinds of spelling errors, ommisions, etc. ( I put a lot of ads on Ebay). So I want the page to THINK it see's

    image

    when it's on my home computer, even though it is just a folder on that same computer simulating my images dir on my web site.


    Thanks!
    Ken
    : If I understand you right you want to develop your website on your home computer and use images in your offline website.
    : That's all possible and if your connected on the net when you're developing you can just use the URL to get the images you don't have on your harddisk at home.
    :
    : If you have an image on your home computer just use this:
    : [code]
    : image
    : [/code]
    :
    : If you have an image an a remote computer just use this:
    : [code]
    : image
    : [/code]
    :
    : Hope this helps you out.
    :
    : --=][tReShR][=--
    :
    :

  • WeirdofreakWeirdofreak Posts: 439Member
    It's perfectly possible, in at least two ways.

    The first would be to write a program that changes the image URLs for you, and changes them back when you've tested.

    The second, and probably easier (if less interesting and popular) way would be to use a Javascript to loop through all the images, and change the domain part of the src to the location on your hard drive. If you embed it using you only have to add or remove one line to get it to work.

    Something like
    [code]window.onload = function () {
    for (i = 0; i < document.images.length; i++)
    document.images[i].src.replace('www.domain.com','images');
    }[/code]
    Should do it, then save that as a .js (or anything else, but .js for preference) file and include it in the page with
  • kjmorfordkjmorford Posts: 4Member
    I've done that. It doesent work well in design because the javascript must not be executing in frontpage (or any other editor I've tried). It works in the browser. So there are complicated ways around it, but there MUST be a way to simulate a web address.

    : It's perfectly possible, in at least two ways.
    :
    : The first would be to write a program that changes the image URLs for you, and changes them back when you've tested.
    :
    : The second, and probably easier (if less interesting and popular) way would be to use a Javascript to loop through all the images, and change the domain part of the src to the location on your hard drive. If you embed it using you only have to add or remove one line to get it to work.
    :
    : Something like
    : [code]window.onload = function () {
    : for (i = 0; i < document.images.length; i++)
    : document.images[i].src.replace('www.domain.com','images');
    : }[/code]
    : Should do it, then save that as a .js (or anything else, but .js for preference) file and include it in the page with
    :

  • WeirdofreakWeirdofreak Posts: 439Member
    You should have IE even without the internet - it comes with Windows. You don't need to be connected to run it, you can still view local pages.

    The other way (modify the file with a script + re-modify it afterwards, or possibly just save a backup and go back to that) would probably have to be written in C (I don't know any interpreted languages which come with Windows), which I don't know, and which you'd need a compiler for anyway.
  • JonathanJonathan Posts: 2,914Member
    : I am NOT a great web designer. I dont want to be. I tinker enough to make it look good though. Here's my problem. I do a lot of work at home and I do not have internet on my computer. I host my images on a web server. I would like to be able to develop on that home computer. Is there a way to make my computer think some folder with my pictures in it is www.whatever.com/images? I know I can just change the code to look for the file , but I do these for auctions on ebay, and I do an awful lot of them and the potential for error would be high. I get around it by just not seeing the pictures when I develop it and testing it later. Very time consuming.
    :
    : Is there anything i can do? I'm more interested in if it can even be done now, than actually doing it.
    :
    : Oh, I have downloded windows web servers but the closest i could get was to assign an ip address to a location on my drive. I dont want that.
    :
    You're almost there, you just need to trick Windows into thinking that the domain name www.whatever.com resolves to that IP address. If you look in your Windows directory (or maybe it's windows system, do a search) then you'll find a file that is named "HOSTS" (no extension). This lets you set up name ==> IP mappings. Open it up, and on a new line add:-

    www.whatever.com 123.123.123.123

    I've done tricks like this before and got it to work, though it was a while ago...anyway, hope it helps.

    Jonathan

    ###
    for(74,117,115,116){$::a.=chr};(($_.='qwertyui')&&
    (tr/yuiqwert/her anot/))for($::b);for($::c){$_.=$^X;
    /(p.{2}l)/;$_=$1}$::b=~/(..)$/;print("$::a$::b $::c hack$1.");

  • JonathanJonathan Posts: 2,914Member
    : It's perfectly possible, in at least two ways.
    :
    : The first would be to write a program that changes the image URLs for you, and changes them back when you've tested.
    :
    : The second, and probably easier (if less interesting and popular) way would be to use a Javascript to loop through all the images, and change the domain part of the src to the location on your hard drive. If you embed it using you only have to add or remove one line to get it to work.
    :
    : Something like
    : [code]window.onload = function () {
    : for (i = 0; i < document.images.length; i++)
    : document.images[i].src.replace('www.domain.com','images');
    : }[/code]
    : Should do it, then save that as a .js (or anything else, but .js for preference) file and include it in the page with
    :
    Bleh...JavaScript sucks. :-S

    If I remmeber correctly, HTML has a tag that lets you set up a prefix for files loaded from that page. Something like:-



    If you wanted a change-one-line-on-the-page solution, that'd be more reliable that the JavaScript.

    Jonathan

    ###
    for(74,117,115,116){$::a.=chr};(($_.='qwertyui')&&
    (tr/yuiqwert/her anot/))for($::b);for($::c){$_.=$^X;
    /(p.{2}l)/;$_=$1}$::b=~/(..)$/;print("$::a$::b $::c hack$1.");

  • lance21lance21 Posts: 2Member
    I use HTML for offline web development. Just save your html code with .htm and run it using any internet browser even offline it should open.

    [link=http://theteakpatio.com]adirondack chairs[/link]






  • melopongcomelopongco Posts: 4Member
    I do the same as yours especially when i don't have internet connection.


    [link=http://www.dramaholics.com]dramaholics[/link]
    [link=http://www.dramaholics.com]korean drama[/link]
  • samuelinsamuelin Posts: 3Member
    That website no longer exist and a adv website in its place.
«1
Sign In or Register to comment.