contact  |  about  |  sitemap

Replacing * in a text
Last Post 19 Apr 2010 03:39 AM by Extractor. 3 Replies.
Sort:
PrevPrev NextNext
Author Messages Not Resolved
Extractor

--
18 Apr 2010 05:51 AM
I save the images of a post in the sub-folder named after the post's title.

But there are some characters that can't be used in the name of folder, i.e., /\:*?"<>|

So I add those characters into a list, and replace them with underscore '_'
Loop List
Replace Text
End Loop


It works fine except for the asterisk, which is used as wild-card in the Replace Text action.


How can I replace the character '*' ?
Extractor

--
18 Apr 2010 06:11 AM Correct Answer?
and FYI, I also use Loop List and Replace Text to escape ' , LF, and CR that are not allowed in a SQL query. It took me some time to figure out that the LF and CR caused the problem. We need a mysql_real_escape_string() action here.
Tijn

--
18 Apr 2010 11:53 AM Correct Answer?
I think you should try a regular expression with the Match Regex action.
Extractor

--
19 Apr 2010 03:39 AM Correct Answer?
yap,

Match and Replace RegEx in [title] with regex \* and replace with _

works fine so far.

Thanks.


Quick Reply
toggle
  Username:
Subject:
Body:
Security Code:
Enter the code shown above:

Submit

Powered by Active Forums

Forum participation and optional registration

You don't need to be registered to partcipate in the Djuggler forums, however if you want to subscribe to email notifications you need to register. You can also subscribe to the forum RSS feed.