Jump to content

(e32) Custom Sidebar Blocks


(e) Eric
 Share

Recommended Posts

We just updated our forum to 3.3.3 and updated the plugin also, but we're now experiencing something odd.

We use the plugin to add in some social links on our forum - such as a Facebook Like box. With the latest version, the plugin refuses to save the HTML code.

For example, pasting the following code into the block box in the AdminCP will not be saved:

<iframe src="//www.facebook.com/plugins/likebox.php?href=https%3A%2F%2Fwww.facebook.com%2Fpage&amp;width=250&amp;height=62&amp;colorscheme=light&amp;show_faces=false&amp;border_color&amp;stream=false&amp;header=false&amp" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:250px; height:62px;" allowTransparency="true"></iframe>

But, if you enter just plain text (e.g. "fidsanf idsnfidsnfsidnf fidsnfinsd"), it'll save fine.

Now, if I enter the above iframe HTML code directly into the csb_content column, it'll display just as expected. But if you then try to edit the block in the AdminCP again, it'll be removed.

Has this already been reported, or am I missing something? I've tried re-installing multiple times with no luck.

Hope that makes sense.

Link to comment
Share on other sites

I just tried that iframe code on my test board and it works fine, well, it is giving me an error that the link is bad, but the CSB is behaving correctly. I have still yet to upgrade my boards to 3.3.3, so it's possible IPS changed the post parser (yet again), in which case I would need to adjust it. I'll try to update to 3.3.3 soon, and will report back once I do and test out some blocks.

If anyone else running 3.3.3 would care to test, by all means do so. :)

Link to comment
Share on other sites

Look in the embed code, there should be the words width and height, follow by an equals sign and then a number. And each might be listed twice. You'll want to change them (one or the other or both, I forget) to a smaller number. Something like 250 or so.

Link to comment
Share on other sites

Really great app, lots of uses. I am having an issue with block placement though. I'm using the main block for "Video of the Week" and treating it as a category to show above all forums. I have an additional block labeled "Welcome Center" that I'm trying to treat as side-bar block. The issue I'm having is that when editing the hook files to sort the two blocks, It will not save as wanted. Either both blocks are treated as category or both blocks treated as side-bar block. Even after several attempts to save it will automatically revert to previous settings.

Suggestions?

- old guy

Link to comment
Share on other sites


I just tried that iframe code on my test board and it works fine, well, it is giving me an error that the link is bad, but the CSB is behaving correctly. I have still yet to upgrade my boards to 3.3.3, so it's possible IPS changed the post parser (yet again), in which case I would need to adjust it. I'll try to update to 3.3.3 soon, and will report back once I do and test out some blocks.



If anyone else running 3.3.3 would care to test, by all means do so. :smile:



same here on 3.3.3, saved fine but there is nothing there.
possibly replace %3A%2F%2F throughout with correct ansi and test it?
seems to me to not be a custom block issue though IMO.
Link to comment
Share on other sites

Hi Eric,

I am getting the following error when Saving a Block. Do you ahve any idea what would cause this?

www.supersupporter.net Driver Error

There appears to be an error with the database.
If you are seeing this page, it means there was a problem communicating with our database. Sometimes this error is temporary and will go away when you refresh the page. Sometimes the error will need to be fixed by an administrator before the site will become accessible again.

You can try to refresh the page by clicking here

Link to comment
Share on other sites


Really great app, lots of uses. I am having an issue with block placement though. I'm using the main block for "Video of the Week" and treating it as a category to show above all forums. I have an additional block labeled "Welcome Center" that I'm trying to treat as side-bar block. The issue I'm having is that when editing the hook files to sort the two blocks, It will not save as wanted. Either both blocks are treated as category or both blocks treated as side-bar block. Even after several attempts to save it will automatically revert to previous settings.



Suggestions?



- old guy




I'm not sure I understand. Custom Sidebar Blocks only work on the sidebar. There is no notion of a "category block" in this app. Perhaps you meant to post in one of the mods that moves blocks to various places on your board? In any case, good luck! :)


same here on 3.3.3, saved fine but there is nothing there.


possibly replace %3A%2F%2F throughout with correct ansi and test it?


seems to me to not be a custom block issue though IMO.



Thanks for testing! Sounds like it might be an issue with the content, not the block.


Hi Eric,



I am getting the following error when Saving a Block. Do you ahve any idea what would cause this?



www.supersupporter.net Driver Error



There appears to be an error with the database.


If you are seeing this page, it means there was a problem communicating with our database. Sometimes this error is temporary and will go away when you refresh the page. Sometimes the error will need to be fixed by an administrator before the site will become accessible again.



You can try to refresh the page by clicking here




That is a generic DB error. You'll want to recreate the error then go into your SQL Error Logs in ACP and look at the most recent error. If it doesn't make sense, post it here and we'll have a look. :)
Link to comment
Share on other sites


I'm not sure I understand. Custom Sidebar Blocks only work on the sidebar. There is no notion of a "category block" in this app. Perhaps you meant to post in one of the mods that moves blocks to various places on your board? In any case, good luck! :smile:



System > Applications and Modules > Manage Hooks > e32 Custom Sidebar Blocks > Edit Hook > Files > File # > The Hook 'ID' > Categories > then select the position of the template hook.

I currently have the "Video of the Week" positioned below the shoutbox but above all other forums like so....

8e89a3c1.png?t=1341948418

Like I said in previous post concerning multiple blocks, all blocks position together, either all as sidebar blocks or all as category blocks.

Anyhow, thanks for the response eric! :smile:
Link to comment
Share on other sites


Hi (e) Eric. Just found your app and it's freakin' awesome.


One question. I have a News forum and I would like to display the latest news in that box.


Could you please help me out ?


Thank's.




Sorry for missing this earlier...

I think you might be able to do that already. Isn't there a Latest Topics hook, and you could choose just the New Forum? Else, there might be a block for that for IP.Content, and you can use that in CSB. If you search this thread there are examples of IP.Content blocks used as CSBs.
Link to comment
Share on other sites

I have been using this for quite a while and never found any issues, until I tried to enter a javascript code yesterday. reading above I am not sure if the problem exists within this mod or with the code, though I can make the code function properly on a test page.

the code is

<div id="ts3viewer_996112" style="width:; background-color:;"> </div>



<script type="text/javascript" src="

http://static.tsview...r.js"></script>

<script type="text/javascript">


<!--


var ts3v_url_1 = "

http://www.tsviewer....ration_h=none";

ts3v_display.init(ts3v_url_1, 996112, 100);


-->


</script>



It should display a tree list and current users on a teamspeak server, but instead all I get is the code being printed in the block. Anyone who can help me figure out why please?

EDIT: I tried the suggestion above and entered the code directly into the database. Works fine, as long as I do not edit the block through ACP
Link to comment
Share on other sites

The code is


<div id="ts3viewer_996112" style="width:; background-color:;"> </div>


<script type="text/javascript" src="http://static.tsviewer.com/short_expire/js/ts3viewer_loader.js"></script>


<script type="text/javascript">

<!--

var ts3v_url_1 = "http://www.tsviewer.com/ts3viewer.php?ID=996112&text=e8d8d8&text_size=12&text_family=1&js=1&text_s_weight=bold&text_s_style=normal&text_s_variant=normal&text_s_decoration=none&text_s_color_h=525284&text_s_weight_h=bold&text_s_style_h=normal&text_s_variant_h=normal&text_s_decoration_h=underline&text_i_weight=normal&text_i_style=normal&text_i_variant=normal&text_i_decoration=none&text_i_color_h=525284&text_i_weight_h=normal&text_i_style_h=normal&text_i_variant_h=normal&text_i_decoration_h=underline&text_c_weight=normal&text_c_style=normal&text_c_variant=normal&text_c_decoration=none&text_c_color_h=525284&text_c_weight_h=normal&text_c_style_h=normal&text_c_variant_h=normal&text_c_decoration_h=underline&text_u_weight=bold&text_u_style=normal&text_u_variant=normal&text_u_decoration=none&text_u_color_h=525284&text_u_weight_h=bold&text_u_style_h=normal&text_u_variant_h=normal&text_u_decoration_h=none";

ts3v_display.init(ts3v_url_1, 996112, 100);

-->

</script>





I did notice that when saving this directly in the ACP block edit, the code gets changed quite a bit. Also when I preview the above it is not the same formatting.

The code can be generated here

Link to comment
Share on other sites


Sorry for missing this earlier...



I think you might be able to do that already. Isn't there a Latest Topics hook, and you could choose just the New Forum? Else, there might be a block for that for IP.Content, and you can use that in CSB. If you search this thread there are examples of IP.Content blocks used as CSBs.




I asked invisionpower about modding the Latest Topic hook and it's a no go.
As for what you said after, I'm sorry but I don't really understand.
I have 0 programming skills, sorry.
Any help (preferably in plain English) would be appreciated.
Thank you and sorry for being a noob.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...