|
#1
|
|||
|
|||
|
Is it possible to use php instead of regular html?
I changed the image_template.html to image_template.php so I can use a php command. I also changed index.php - by finding all the image_template.html and changing the extensions to .php am i missing anything else to change it entirely? Because the php code I'm using isn't initiating the way it's suppose to. Thanks in advance! |
|
#2
|
|||
|
|||
|
no, you cannot as the script looks for HTML
you cannot include php in Pixelpost templates if you know what you do you can try and test, but we cannot give you support for that as I would say, you cannot include php in php other than using include() function, but included it will not render the tags why don't you write an Addon? The AddOns are the interface for that, they get rendered... so write an Addon, let that Addon create a Tag and place this Tag into your template and you are on the safe way and can follow the coming upgrades Pixelpost's principle: KISS! (Keep It Simple, Stupid!) good luck, Connie |
|
#3
|
|||
|
|||
|
@Connie: Thanks for the suggestion =)!
However, I'm not that "GOOD" to be able to write an addon, sadly =*(. Anyone willing to help? It would be greatly appreciated! <3 |
|
#4
|
||||
|
||||
|
As it is open source, yes you can but dont expect any future support from us. Noone made official hack so you will be first who is trying to execute own code with Pixelpost from this side. You must change all template calls to supporting PHP extension instead of HTML (try to grep/search in source for .html).
|
|
#5
|
|||
|
|||
|
I have been able to call in PHP scripts via an include.. well, sort of an include.
I just did a mod in my index.php, for the time being - - until I do it with an addon .. which I will do another day. But for today - my code looks roughly like this: Code:
$phpinclude_output = file_get_contents('your_file.php');
$tpl = ereg_replace("<PHP_INCLUDE_1>",$phpinclude_output,$tpl);
I make a few hundred bucks every month selling text ad links - they serve the text ads to my site via PHP... so I was motivated to get that piece of code working
__________________
![]() -------------------------------------------------- Photoblog: Snapping Photos Personal blog: Just A Girl |
|
#6
|
|||
|
|||
|
Snap,
please do this as an addon, I suggest as an Admin-Addon because then the admin defines the text which should be included we try not to suggest any hacks here anymore because the memory of people is short and life is long... and after updating their hacks won't work anymore ;=) |
| Post Reply |
| Thread Tools | |
|
|