Timeline for Add video tag to youtube link fron content
Current License: CC BY-SA 3.0
15 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jul 2, 2015 at 11:23 | comment | added | Zamalek Man | print_r not work with me because i use echo, when test it out the file and use print_r , its show my duplicate | |
Jul 2, 2015 at 11:08 | comment | added | marcovega | Do a print_r($matches) after the preg_match and get the variable you need. | |
Jul 2, 2015 at 11:02 | comment | added | Zamalek Man | i edit your code to echo "<video>$match[1]</video>"; but why show 2 video if its have one link ? | |
Jul 2, 2015 at 9:56 | comment | added | marcovega | Let us continue this discussion in chat. | |
Jul 2, 2015 at 9:55 | comment | added | Zamalek Man | i do that but not work | |
Jul 2, 2015 at 9:50 | comment | added | marcovega | Maybe it's because $post->post_content has html entities encoded. Try wrapping html_entity_decode($post->post_content) in the preg_match_all | |
Jul 2, 2015 at 9:47 | comment | added | Zamalek Man | sorry, but still not work | |
Jul 2, 2015 at 9:45 | comment | added | marcovega | It's different, see here: wordpress.stackexchange.com/posts/193283/revisions | |
Jul 2, 2015 at 9:44 | comment | added | Zamalek Man | its same old code :-) | |
Jul 2, 2015 at 9:40 | comment | added | marcovega | I have edited my answer with a new regex code | |
Jul 2, 2015 at 9:39 | history | edited | marcovega | CC BY-SA 3.0 |
edited body
|
Jul 2, 2015 at 9:36 | comment | added | Zamalek Man | i edit my post, see it | |
Jul 2, 2015 at 9:20 | comment | added | marcovega | What's inside your post? How does it look like? The output of $post->post_content | |
Jul 2, 2015 at 9:18 | comment | added | Zamalek Man | thank you, but i test it and not work with me, its not print any thing | |
Jul 2, 2015 at 8:49 | history | answered | marcovega | CC BY-SA 3.0 |