Blobs inside {php}

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
rcp

Blobs inside {php}

Post by rcp »

Hi!
Is it possible to access blobs in {php} blocks inside pages and templates?
For instance:


Thanks in advance!
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm
Location: Fairless Hills, Pa USA

Re: Blobs inside {php}

Post by Ted »

Not directly.  The way I would handle this is...

Make user defined plugin.  Call it my_urlencode.  In the code, put:

Code: Select all

echo urlencode($params['value']);
Then, in your template/page, do:

Code: Select all

{capture name='bloboutput'}{html_blob name='blah'}{/capture}
{my_urlencode. value=$smarty.capture.bloboutput}
Not tested, of course.  But I believe this should work.
rcp

Re: Blobs inside {php}

Post by rcp »

Oh, how cumbersome...
Many thanks!
Post Reply

Return to “Developers Discussion”