New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improving documentation on adding images #1222
Comments
Correct me if I am wrong, but... the (kinda weird) thing is, to access external images you need the Alternatively, what you may need to use instead is actully the native html
|
That's the thing. Ideally I wouldn't want to access external images at all (this was only to test things). Plus, the documentation about external images would make me avoid them as much as possible.
I did try the |
Hi @anavarre There's a couple of things going on. First, to add a jpg/png image to a wiki folder you need to add an accompanying https://github.com/Jermolene/TiddlyWiki5/tree/master/editions/tw5.com/tiddlers/images Secondly, external images are not yet supported in the client-server configuration: But lazily loaded images are supported: |
Aha! Still no bueno, but I hope we're on the right track. I've added a test.jpg.meta alongside test.jpg - Content of the file looks like this (source field seems optional):
Then tried the below variations without more luck:
Looks to me that TiddlyWiki needs the relative path anyway so I shouldn't be able to link to the test image without having ''img/" in the path. Tried that out of despair, TBH ;-) I have to run now and will come back to this tomorrow. I'd like to thank you both for your time already! |
Try {{test.jpg}} On Fri, Dec 12, 2014 at 6:32 PM, Aurelien Navarre
|
Hi @anavarre If you've successfully added the image with the title "test.jpg" then you should be able to see "test.jpg" listed in the "All" tab of the sidebar. Secondly, the fact that you've put the image in a folder called "img" inside the "tiddlers" folder is ignored; the title of the tiddler is as given in the Thirdly, with an image loaded in this way, the only syntax that should work to display it are the following:
Fourthly, it looks like maybe you've got a blank line at the start of the |
If you're talking about the More tab in the sidebar, then the All vertical tab, then, perhaps this is my issue. I don't see the test.jpg file listed there.
I'm not sure I parsed that right. As I understand:
Ack.
This is an artifact of minimizing the shell prompt. There's no extra line/space that would be an issue here. |
BTW I tried putting the Didn't think it would be so complicated to add an image. Very sorry to bother you like that. EDIT: aha, I tried something that I was fairly certain wouldn't make any difference. Restarted the node.js server and now I am seeing the image both registered in the I'm still trying to understand what is happening here and I'll brb with more as soon as I've performed a few additional checks. |
If it's any consolation, adding an image to a Node.js wiki is easy. It's not previously something that we've had trouble with, so I'm assuming that there's something really basic going wrong that I'm missing.
Basically, you can organise the contents of the
No. The filename of the image is not related to the title of the tiddler.
No, the I guess to take this further it may be useful for you to share a repo/gist with the content of your wiki folder so that I can look it over? |
@Jermolene many thanks for the additional clarification. Please refresh the issue page and have a look at my updated comment above :-) Overall good news and a node.js server WTF I'm not currently able to explain. |
Ah, good to hear @anavarre. Other people have certainly been caught out by expecting changes in the filesystem to be dynamically loaded without a restart. If you do need to add tiddlers to a running instance you can use the HTTP API to make changes. |
Oh, this is normal behavior, then? I've been living under the promise that node.js was all about real-time. Would that be any relevant to try and improve the TiddlyWiki documentation by stating that images not being displayed might be because the node.js server needs to be restarted first? |
It's how TiddlyWiki was designed. The best, most general way to interact with a running wiki is via the HTTP or JavaScript API, rather than manipulating the file store directly (which we may also support in the future).
Yes, except that this isn't just about images, it applies to any modification to the contents of the wiki folder. |
Submitted a PR #1227 - See you there. Once again, many thanks for your patience and understanding here. Very much appreciated. |
I'm new to TiddlyWiki, so please bear with me as I feel really dumb filing this issue already :-)
I can't seem to be able to add local images to my TiddlyWiki instance. I volunteer to improve the documentation when I know how to actually easily include images.
Above, please note that I've added the same image (
test.png
) in two different locations to rule out possible incompatibilities with subdirs.Tried:
None of this worked nor by trying to use the HTML
<img>
tag either. I also tried variations (jpg, jpeg and png images) and I'm never able to get them to show so I'm a bit at loss and wonder what I'm doing wrong.FYI I read the notes Images in WikiText and ExternalImages on the official site but it didn't help me it seems.
The text was updated successfully, but these errors were encountered: