TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

May 22, 2024, 03:53:15 PM

Login with username, password and session length
Members
Stats
  • Total Posts: 195,197
  • Total Topics: 21,221
  • Online today: 226
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 155
  • Total: 155

Poll images in front page block

Started by lurkalot, July 06, 2010, 11:22:17 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

lurkalot

Running  SMF 1.1.11 TP 0.9.8 and using images in the polls.

We currently put the image code into the poll option texboxes, so this displays the image next to the selection box. Like this,

http://cameracraniums.com/forum/index.php?topic=1436.0

I've installed the SMF poll mod and can now pull this poll complete with images to my front page. using a php block with this code in it,

ssi_showPoll(X); - For a single fixed poll where X is a topic number.

My question.  By adding some code to the block is there a way to resize and add some sort of layout to these images?  like a 4x4 image square.

Any help would be appreciated.

mattb

try using photoshop to resize the pcitures to 4x4 :D

lurkalot

Matt to be honest I would do that if the content was kind of permanent.

The images linked to the forum polls are the intermediate images from my coppermine gallery.  The weekly comp polls are set up by my members so they need to just link to the images for the current weeks entries.

mattb

TP 0.9.8

I think a updated version of TP has a fix for that. Not sure.

lurkalot

Quote from: mattb on July 07, 2010, 12:51:54 AM
TP 0.9.8

I think a updated version of TP has a fix for that. Not sure.

Matt, it's not a fix that's needed it all works as designed. 

I just wondered if the block could be modded slightly for our needs.  We run a weekly comp, and rather than have to go to the forums to vote we would like to do this directly from our home page.  Obviously the images are just too big and in one vertical line to have on the front page as is.

lurkalot


Freddy

When you call the ssi_showPoll function, all the processing has already been done - so it's like the horse has already bolted...

I would look at the function in detail and see if it will return an array of information rather than directly formating the output itself.

If you can return an array with that function then you should be able to make you own layout.

I don't know this mod, perhaps the mod author could help.

lurkalot

Quote from: Freddy on July 07, 2010, 08:27:56 PM

I don't know this mod, perhaps the mod author could help.


Thanks Freddy, but the mod author hasn't been about since February this year.  This is the mod though if anyone's interested, http://custom.simplemachines.org/mods/index.php?mod=765

I also posted on the support thread for the mod, but haven't had any replies.  :'(

So what you're saying is it's the code in the mod I installed that needs altering, rather than the block code?  Methinks this will be beyond my scope without help.  :-[

mattb

Have you posted on the smf site? showing the layout of your code. And what you would like to alter etc..

lurkalot

Quote from: lurkalot on July 07, 2010, 08:51:22 PM

I also posted on the support thread for the mod, but haven't had any replies.  :'(


As said above Matt.  ;)