We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33241
    • 9 Posts
    Dear Modx community!

    I’d like to know how is it possible to set a placeholder’s value by a self written module. I’d like to make an interface for my manager users to be able to choose between different pictures, and set the value of a placeholder by selecting one of them (i need only a placeholder for different values for my css). Do i have to write a php code (a form) to let them pick a picture, and post a parameter to a placeholder’s value? And if so, how can i make the connection between them?

    Another thing, what isn’t clear for me:
    I have a [+place+] placeholder in my template, and a snippet, called placeholder, what should fill this placeholder in with some content. It is working if i put the snippet call [!placeholder!] right after [+place+] in my template, but if i’m doing this in my own module, it refuses to work:

    $place = $modx->runSnippet(’placeholder’);

    I’m a bit newbie in making modules, but i have to understand how they work pretty fast, so sry for my questions.

    Ty in advance!

    Ysera