![]() |
|
Thread Tools |
#1
|
||||||||
|
||||||||
Vb Api Extension returns data and shows always after <body>
I am creating a Api Extension with the help of Wordpress Header & Footer Integation
I am almost done and everything seems to be in order except, whenever I return a data, it always goes on the top of the browser, after the <body> tag, example given below:
header-forums.php file simply contains an echo statement. VB displays it, but shows it on the top, even above the main-navbar-wrapper. However, the weird part is, if I do the following, it shows where the hook is supposed to show it
Any help would be highly appreciated. No members have liked this post.
|
#2
|
||||
|
||||
The echo statement is the problem. VB wants to display the returned data. Assign your data to a variable and return the variable.
$data = '<h1>My Custom Footer</h1>'; return $data; The following members like this post: In Omnibus
|
#3
|
||||
|
||||
Originally Posted by Replicant
Well the issue isn't with the second piece of code from my post, outputting the following is causing the issue![]()
No members have liked this post.
|
#4
|
||||
|
||||
Using an echo will show at the top of the page like a debug marker. You need to remove the echo.
in your snippet, you're doing "return;" You need to put the data in a variable and "return $data;" The following members like this post: MarkFL
|
![]() |
Tags |
api extension, footer, header, vb5, wordpress |
«
Previous Thread
|
Next Thread
»
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
|
|
New To Site? | Need Help? |
All times are GMT. The time now is 01:58.