Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
general-topic
Change Button Title
Avatar
Bob Christensen
Olympia, WA
Member
Free Members
sp_UserOfflineSmall Offline
Jul 1, 2012 - 7:19 pm

In an earlier post, you mentioned that you changed the title of the "Upload Attachment" button to something more meaningful. Is that difficult to do? Would you explain how? Thanks!

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 1, 2012 - 9:40 pm

Did we?  dont remember that... possible but a bit involved... unfortunately, that button, given how the uploader works and needs to be located, cannot really be done with a template tag... but it can be changed..

In your spFunctions.php file of your sp theme (and please make sure its your own theme: http://codex.simple-press.com/.....g-a-theme/), add this code:

add_filter('sph_uploader_editor_section', 'my_uploader_section', 10, 5);
function my_uploader_section($out, $type, $uploadImages, $uploadMedia, $uploadFiles) {
    if (empty($type) || $type = 'edit') {
        $out = str_replace('Upload Attachments', 'Some String', $out);
    }
    return $out;
}

should do it though I have not actually tested... Of course, replace Some String with what you want the button to say...

And I can see if I can simplify that in an future version of the file uploader...

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626