Fork me on GitHub

SetVars in arrays?  Bottom

  • Is it possible to use the pnModSetVars to set an array? I need to be able to handle a list of file extensions to block in uploading, but I'm not sure what the best way of handling it would be. TIA!
  • pnModSetVar (note no 'S') won't handle an array automatically but you can store an array (or object, resource etc.) as a module var by serialising the content first (unserialise things the other end).

    e.g. pnModSetVar('mymod', 'myvar', serialize($myarray));

    and $myarray = unserialize(pnModGetVar('mymod', 'myvar'));

    -Mark

    --
    Visit My homepage and Zikula themes.
  • 0 users

This list is based on users active over the last 60 minutes.