The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#21
|
||||
|
||||
Try the code below:
PHP Code:
Let me know how it goes. |
#22
|
|||
|
|||
Quote:
Parse error: syntax error, unexpected ':' in public_html/forum/global.php(28) : eval()'d code on line 3 |
#23
|
||||
|
||||
Quote:
PHP Code:
|
#24
|
|||
|
|||
Quote:
--------------- Added [DATE]1258383869[/DATE] at [TIME]1258383869[/TIME] --------------- One more question, why did you add the "HTML" at the end of the variable? |
#25
|
|||
|
|||
Because the template example he gave the name of the template was $abcHTML thats all in his example.
Now the point I am making is I can make what I am doing work by defining a new hook works great. even pre registering values can work fine but that still means you need to hand edit the actual template you want to insert it to and place the variable there. With str_replace you never had to hand edit templates plugins where just that true plugins without having to touch the vb code. If I upgrade vb then one will have to redo there template edits which to me is a huge design flaw. If the vb developers are going to lock you into doing things a certain why then they really need to place template hooks in alot of places. |
#26
|
||||
|
||||
Since I am at work, I cannot check your assertion that str_replace() cannot be used, but even if it were true, its not a design flaw in vb4 - it was never an official plugin method, but mearly a hack that happened to work. So if anything, it was a design flaw in 3.x
Off the top of my head, I cant think why it would no longer work, but as I said, Im at work, so cant check anything. |
#27
|
||||
|
||||
Quote:
|
#28
|
|||
|
|||
I already did my friend in post 13 I basically responded right to you when you asked me to post the code.
I defined one variable for use in my template as thats all that is needed but I can not get the template included where I want because there is no hook using a str_replace Defining a new hook works great thats not an issue but I want to keep from having to hand edit vb templates in any manner. https://vborg.vbsupport.ru/showpost....6&postcount=13 |
#29
|
||||
|
||||
Quote:
Anyway, I don't think your search/replace is correct. You wrote: PHP Code:
PHP Code:
|
#30
|
|||
|
|||
If I do what you say its a parse error. In all my days of PHP you need to escape quotes when you use html in a php file.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|