Hi all,
New to Drupal and i'm having a real hard time to upload an image to my content. When i create content (in this case a page) i have the possibility to add an attachment but i guess that's not the way to go. Besides, that gives me the dreadfull http 0 error (using Opera) although it uploads the image to the server but doesn't show it.
I've installed and enabled the required modules (Imagefield, Imagecache etc....), added a new preset in Imagecache, added a new field called Image to the content type page so i was under the impression that when creating the page i was presented a field that would allow me to upload an image but that isn't the case.... Am i completely missing the boat here? Or do i need to install another special module for this? I'm also using Ubercard....
Comments
Just want to double check the
Just want to double check the steps:
*Are you using Filefield (http://drupal.org/project/filefield) and Imagefield (http://drupal.org/project/imagefield) along with CCK? With these, the field type you're looking for when you add it to the content type is under "file" and then the widget is "image." If you aren't using these, use them. Very robust and works with imagecache and many other modules too.
*Remember fields are automatically added at the bottom of content, I sometimes forget to move them above all the other mishmash of settings and then think I didn't add them.
*Check your display settings to on the Display Fields tab and make sure they aren't hidden.
*If you're not logging in as the admin account, be sure you also have set permissions that you can upload files.
Alan
Hi Alan, tnx for your reply.
Hi Alan,
tnx for your reply. Yes, i'm using those modules and i've created both a new file filed and image field as described in the install.txt for page content type. I've moved them up, right under the body field. They show up on the Display fields tab. For the image tab, i used the preset i created in Imagecache for teaser. Permissions are ok. Yet, the fields dodn't show up when creating a page .... am i getting bunkers in my old day?
Nobody has a clue ?
Nobody has a clue ?
Can you verify that
Can you verify that Imagecache is actually creating the re-sized images? If it is you will find them located under - sites/files/imagecache.
Yes it is. But the problem is
Yes it is. But the problem is that i can not upload an image because i don't have an 'upload image' field although it' s all set up. So how do i add an image to my page????? Do i need to install yet another module just for adding images to my pages???
I've followed the tut here: http://drupal.org/node/609628 and http://drupal.org/node/163561 so i was under the impression i would be presented with the possibility to upload an image using a filed for this but even when i go to add content and choose 'image', i'm presented with the same fields the 'add page' has: title, body et such....
_
Did you enable the content permissions module (part of cck) by chance?
Yes that's enabled
Yes that's enabled
I think the point WorldFallz
I think the point WorldFallz was trying to make is that you should disable the content permissions module and see if that has any effect. It's certainly not needed to enable uploading images. It's used to control access to individual fields for specific user roles.
Great! Now the fields show up
Great! Now the fields show up except i'm getting the following error on uploading: An HTTP error 0 occurred.
/projects/drupal/filefield/ahah/image/field_image1/0. The first image doesn't show up but it's on the server at /projects/drupal/sites/default/files?? The second i tried to upload is located in /projects/drupal/sites/default/files/uploaded_images...
Do i first need to create those filefield/ahah/image/field_image1/0 directories???
_
No-- sites/default/files is the default directory. If you don't have a specific reason to change it, you don't need to. And no, you don't need to create the 'ahah' path. Ive seen posts about that 'http 0' error-- you should be able to find them pretty easily.
_
yep-- once you enable the content permissions module, you have to explicitly grant permissions to use fields. By default, no roles have any permissions to fields. If you don't need the module then disable it (always a good idea with modules you're not actually using). If you do need the module then simply set permissions as desired at admin/user/permissions. Also, the field_permissions module ( a separate module) is a bit more user friendly.
I've just tried with Safari
I've just tried with Safari and there's no http error ... seems something related to the Opera browser .... but that's no big deal at the moment for me .. tnx for the help.
I've only get have one more question ... is there a way to get an image inside the body text?
_
There's probably a dozen different ways, but my method of choice is described in http://mustardseedmedia.com/podcast/episode29
Tnx Worldfallz, excellent
Tnx Worldfallz, excellent link!!!
A dozen different ways? Hmm.... need to do a search then :-)
I'm a hardcoder so Drupal is totally new for me and i was to lazy to go over all the documentation ... it's a steep learning curve but i'm liking it :-)
Tnx for all the help guys and forgive me if i had some stupid questions!