Support » Everything else WordPress » Integrating script into WP page ( plugin?)

  • Hi! There is this somehow neat plugin I found that I would like to modify and integrate into a WP page.

    It’s a so called “Magnetic Poetry” AJAX plugin:

    I tried to play around with the code and couldn’t get it to work.

    Any kind soul to help me get started? I tried to search around here also but couldn’t a solution (got a couple of hints though).

    Also I thought this could make for a nice little goodie “Fridge Door” plugin. I’d understand if no one was interested in porting this. I never wrote a plugin but was wondering whether that qualify for a start (I know HTML, and enough of CSS/PHP to make my way around WP). I would basically add an admin page where you could manage words and adapt size and some css; I would also like to add some kind of admin “reset” option so words get displayed in a defined initial state.


Viewing 2 replies - 1 through 2 (of 2 total)
  • I’m still trying…
    Here is more info if someone runs across this:

    Basically, the script I wish to integrate uses AJAX and CPAINT to draw a board where there are word tiles; the user may move tiles around the board and tiles keep user entered locations. Words and locations are kept within a pipe delimited .dat file with and ID key, the word itself and coordinates (33|than|566|378). The file is writable so when a tile is being moved, the coordinates get updated.

    See it here :

    The distribution consist in an index file calling the main script which uses CPAINT php files and several .js files.
    All these files are in a same (script root) directory.

    What I tried was to create a “magnet” page template calling a custom header where I put the meta, head and body (onload) elements used by the script (referring to css and js files).

    I modified the src= references in the main script to point to a directory I created at my web root where I put the actual script files.

    That didn’t work. The board would initially get drawn about ok but I couldn’t move tiles.

    One specific question : since I’m using friendly url’s ( where should I put the script’s directory? I tried both the web root and my theme’s directory and it didn’t seem to work.

    Any help would be greatly appreciated! TIA.

    Well, i know this thread s about 7 months old but i tried to do this, too. I didn t succed either. I succeded i including the script in another file in another directory… but i didn t succed in including it in my WordPress template (even though thats just anothter file in another directory, too), so i guesss it s a WordPress issue. Some reason could be the multiple includes WordPress performes, that could possibly also explain why some vars the script sets global become NULL instead of global… weird.

    Some AJAX Whiz around to help us?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Integrating script into WP page ( plugin?)’ is closed to new replies.