News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Post screen

Started by nay27uk, March 23, 2008, 06:43:23 AM

Previous topic - Next topic

nay27uk

i was wondering, is ther anyway of altering the text on the post screen that says (more attachments)
and changing it to a button so it is esier to see. also wher do i alter the attachements bit so it is permanently shown I.E not aditional options dropdown

Eliana Tamerin

Admin CP > Themes and Layouts > Theme Settings > Default theme > Uncheck "Enable Collapsible Options on Post" or something like that.
Do NOT PM me for support.

SimplePortal 2.3.6 is OUT!
SimplePortal Project Manager
Download | Docs
SimplePortal: Power of Simplicity!

nay27uk

thanks and how do i change it to a button for mor atachements

Eliana Tamerin

That will also show the attachments if permission for those is enabled.
Do NOT PM me for support.

SimplePortal 2.3.6 is OUT!
SimplePortal Project Manager
Download | Docs
SimplePortal: Power of Simplicity!

Rumbaar

That is controlled by language files

Post.english.php
$txt['more_attachments'] = 'more attachments';
You can alter that to the HTML to link to an image/button if you like.
"An important reward for a job well done is a personal sense of worthwhile achievement."

[ Themes ]

conectado

QuoteThat is controlled by language files

Post.english.php
Code: [Select]
$txt['more_attachments'] = 'more attachments';You can alter that to the HTML to link to an image/button if you like.

Could you please be a little bit more specific about making the button??

I mean , what should i write instead of
Quote'more attachments';
, if i want to link that option to a button which is in for example: www.hello.com/myfolder/myimage.gif

Thank you very much

conectado

#6
Someone could help me...??

I guess it's not something very complex but i need your help

Thanks

Eliana Tamerin

No, you'd need to alter the line in Post.template.php instead. I'll show you on the default Post.template.php. If your theme has it's own, you will need to alter that too.

Find this:
<span id="moreAttachments"></span> <a href="javascript:addAttachment(); void(0);">(', $txt['more_attachments'], ')</a><br />

Find this part:
(', $txt['more_attachments'], ')

Replace with this:
<img src="http://www.hello.com/myfolder/myimage.gif">

Save and upload the file. That should work.
Do NOT PM me for support.

SimplePortal 2.3.6 is OUT!
SimplePortal Project Manager
Download | Docs
SimplePortal: Power of Simplicity!

conectado

Sorry for my ignorance but this sgould work on smf 1.1.4?

and what is the string to modify (put an image to)  "Reply"

Thanks

Eliana Tamerin

You don't modify strings. Do the same thing you did with this, find the name of the text string in the Display.english.php file, then search for it in Display.template.php. It'll probably be something similar to before, just stick in your <img src="url"> tag where the text variable is.
Do NOT PM me for support.

SimplePortal 2.3.6 is OUT!
SimplePortal Project Manager
Download | Docs
SimplePortal: Power of Simplicity!

conectado

#10
Problem Solved!

Thanks everyone

I found that the string associated with "Reply" was $txt[146]

So i just replaced this in the index.english.php :

$txt[146] = 'Reply';

with this

$txt[146] = '<img src="http://www.hello.com/myfolder/myimage.gif">';

Thanks again



Eliana Tamerin

I would not advise you to put HTML in the language files. Do what I explained, HTML belongs in the template files, not the english files.
Do NOT PM me for support.

SimplePortal 2.3.6 is OUT!
SimplePortal Project Manager
Download | Docs
SimplePortal: Power of Simplicity!

Rumbaar

It should be perfectly fine to place HTML in language strings Eliana Tamerin :)  Also I would say putting it into the languages strings would be better than hard coding it to the template file.  As if you are linking to a image with text you'll want to have a different link for each installed language.
"An important reward for a job well done is a personal sense of worthwhile achievement."

[ Themes ]

Advertisement: