0 votes
by (120 points)
How can I add an image to my story without a link? I want my story to load images without being online.

1 Answer

0 votes
by (158k points)

If you store the image files in a location relative to the story HTML file you are generating with the Publish to File options then use can use a Relative URL to reference it.

eg. If your published story HTML file is named mystory.html and your image file is named forest.jpg, and you are using a local folder & file structure like the following (Window based) one to store both the story HTML file and the image file.


Then you can use a Relative URL like the following to reference the image file from within your Passage, note the usage of a forward-slash to distinguish the folder name from the file name.

<img src="images/forest.jpg">

note: Web-based technologies require the usage of the forward-slash instead of the back-slash used by Windows

When your ready to send to send your published story to someone else or to upload it to either a web-server or file hosting site you will need to make sure to send the image file(s) as well as the story HTML file. One good way to do this is to use an archive file generating tool (like 7zip or WinRar) to add the HTML & images files to a ZIP or RAR file, and then to send / upload that archive file instead.

Welcome to Twine Q&A, where you can ask questions and receive answers from other members of the community.

You can also find hints and information on Twine on the official wiki and the old forums archive.

See a spam question? Flag it instead of downvoting. A question flagged enough times will automatically be hidden while moderators review it.