Topic: [Extension] DivX BBCode Extension 1.1

04-01-2009  New Release 1.1
+ added demo site:
Demo
Download

Add your divx encoded .avi file to   yourdivxfolder  on http://yourwebsite.bla/

then just use

[divx]http://yourwebsite.bla/yourdivxfolder/yourfile.avi[/divx]

Let me know if any probs.
Have fun.

Last edited by KeyDog (2009-01-04 13:31:35)

Re: [Extension] DivX BBCode Extension 1.1

You should use the extension system. smile

Re: [Extension] DivX BBCode Extension 1.1

Tried this:

<?xml version="1.0" encoding="UTF-8"?>
 
<extension engine="1.0">
    <id>divx_bbcode</id>
    <title>DivxBBcode</title>
    <version>1.0.0</version>
    <description>Adds DivXBBCodes to allow divx embeding on your forum.</description>
    <author>KeyDog</author>
    <minversion>1.3 Beta</minversion>
    <maxtestedon>1.3 Beta</maxtestedon>
    <hooks>
        <hook id='ps_do_bbcode_replace'><![CDATA[
        $pattern[] = '#\[divx=(.*)\](.*)\[/divx\]#e';
        $replace[] = '<object width="640" height="380" codebase="http://go.divx.com/plugin/DivXBrowserPlugin.cab" classid="clsid:67DABFBF-D0AB-41fa-9C46-CC0F21721616"><param value="false" name="autoPlay" /><param value="true" name="loop" /><param name="src" value="$1" /><embed src="$1" autoplay="false" loop="true"  width="640" height="380" type="video/divx" pluginspage="http://go.divx.com/plugin/download/"></embed></object>';
        
        ]]></hook>
        <hook id='ps_preparse_tags_start'><![CDATA[
        
        // Added by KeyDog
        $tags[] = 'divx';
        $tags_opened[] = 'divx';
        $tags_closed[] = 'divx';
        
        ]]></hook>
    </hooks>
</extension>

but it didn't work. any ideas where I went wrong?

Re: [Extension] DivX BBCode Extension 1.1

What happens when you try to install it?

Re: [Extension] DivX BBCode Extension 1.1

It just shows the exact code I entered with divx tags

[divx]www.mysite.bla/divx/test.avi[/divx]

Installation itself is not problem, i.e. no warnings etc. But it working is....

Last edited by KeyDog (2008-12-14 17:37:22)

Re: [Extension] DivX BBCode Extension 1.1

That seems quite wrong, on two levels:
1) I doubt you can put an object in an a tag or vice versa;
2) Shouldn't it be [divx]?

So:

[divx]http://www.example.com/divx/test.avi[/divx]

Ben
SVN repository for my extensions - The thread
Quickmarks 0.5
“Question: How does a large software project get to be one year late? Answer: One day at a time!” - Fred Brooks

Re: [Extension] DivX BBCode Extension 1.1

Just FYI the tag above works if I modify parser.php as explained at top. But this extension xml I'm not at home with... I saw on the video_bbcode one there is additional php file for embeded video url - maybe I need additional info in a php file?

Yes to 2.

Re: [Extension] DivX BBCode Extension 1.1

HAD A TYPO. I IDIOT. haha

ok here is link
http://rapidshare.com/files/173330261/d … e.rar.html

extension works my end. try and let me know!

$pattern[] = '#\[divx=(.*)\](.*)\[/divx\]#e';

  i was using

$pattern[] = '#\[divx\](.*?)\[/divx\]#';   

   correct

Last edited by KeyDog (2008-12-14 17:49:45)

Re: [Extension] DivX BBCode Extension 1.1

added bbcode help  [for dev r718]
[@developpers] any reason for the change to the hook: ps_preparse_tag_ends ... ? now with _fn_

Re: [Extension] DivX BBCode Extension 1.1

Naming consistency

Re: [Extension] DivX BBCode Extension 1.1

ok chrs


04-01-2009  New Release 1.1
+ added demo site:
Demo
Download

Add your divx encoded .avi file to   yourdivxfolder  on http://yourwebsite.bla/

then just use

[divx]http://yourwebsite.bla/yourdivxfolder/yourfile.avi[/divx]

Let me know if any probs.
Have fun.

Last edited by KeyDog (2009-01-04 13:31:56)