I wanted new functionality for one of my sites.
I added a %nid token to set the path where the module store the images. I want this because then I can save all the images of a node in one site. After i want to add programatically the images to a cck field by looping over all the files of a node previously stored in the same directory, but I can't do it yet, I'm working on it.
I put some content from feeds and I don't want all the images downloaded until I publish it. So I trigered the download when updating and the status of the node is 1 (published).
During the process of coding i had some problems because of single and double cuotes and lower and upper case, so I've modified a little bit the regexp and added one function for each single and double cuote. Now It should work on
,
,
,
, ...
I've made two patches, one using diff and other using cvs diff. Both have different size and I don't know if its ok or not then I include both patches and my code get_image.module modified.
| Comment | File | Size | Author |
|---|---|---|---|
| get_image_mod.txt | 6.96 KB | carsato | |
| get_image_new_functionality.patch | 6.65 KB | carsato | |
| get_image_new_functions.patch | 8.33 KB | carsato |
Comments
Comment #1
carsato commentedI made a mistake, this
Now It should work on , , , , ...
should be:
Now It should work on
<img*src="*"*>, <img*src='*'*>, <img*SRC="*"*>, <iMg*src="*"*>, ...Comment #2
Ajithlal commentedThanks a lot working fine