• Welcome to Simple Machines Community Forum. Please login or sign up.
January 19, 2022, 10:24:06 AM

News:

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


Custom Action Mod

Started by Norv, May 09, 2006, 08:35:29 PM

Previous topic - Next topic

NanoSector

This won't help with the problem you are having.

Though I don't see anything bad in the test results.
My Mods / Mod Builder - A tool to easily create mods / Blog
"I've heard from a reliable source that the Answer is 42. But, still no word on what the question is."

eyo

do you have an idea what made my editing options in bbc or html have gone?

NanoSector

Quote from: ggman on December 22, 2010, 09:11:40 AM
do you have an idea what made my editing options in bbc or html have gone?
I absolutely have no idea.

Maybe upload a fresh Post.Template.php to your Themes/Default folder.

Warning: This will remove all BBC editing options from the menu.
My Mods / Mod Builder - A tool to easily create mods / Blog
"I've heard from a reliable source that the Answer is 42. But, still no word on what the question is."

Andrew94©

This is a WONDERFUL mod! I'm using it and having a blast with it!

Quick question though - how do the sub-actions work? I made one and can't seem to be able to find out how to get to it.

NanoSector

Quote from: Andrew94 on December 27, 2010, 10:57:46 PM
This is a WONDERFUL mod! I'm using it and having a blast with it!

Quick question though - how do the sub-actions work? I made one and can't seem to be able to find out how to get to it.
I didn't see anyone to have them working, though.
My Mods / Mod Builder - A tool to easily create mods / Blog
"I've heard from a reliable source that the Answer is 42. But, still no word on what the question is."

Andrew94©

I figured it out, it's ;sa=subaction

Example:
http://youwebsite/index.php?action=firstaction;sa=subaction

cloksin

I have a request.  I took over a site for someone who unfortunately is no longer with us.  The site uses simpleportal and has a menu block on the left hand side with all kinds of things in it.  One of the things I need help with are some navigation links that were created using a custom action, unfortunately that custom action got lost in a server crash and I have no idea how to recreate it.  What I am trying to do is create links that my users can use to get to "Topics - Last 50", "Topics - Last 24 hrs", "Topics - You're Watching", "Topics - You've Bookmarked", and "Topics - Unreplied".  This is the code I have in the simpleportal block:

global $context, $settings, $options, $scripturl, $txt, $modSettings, $user_info, $db_prefix, $smcFunc;

// Shows for everybody
echo '<a href="', $scripturl, '?action=links">Links</a><br />';
echo '<a href="', $scripturl, '?action=contact">Contact Webmaster</a>';

// Guests
if ($user_info['is_guest']) {
echo '<center>';
echo '<strong>Registration requires a <u>valid</u>, <u>active</u> email address!!!</strong><br />';
echo '</center>';
echo '<hr>';
}

// Logged in Users (with one line checking for membergroup 13)
if (!$user_info['is_guest']) {
echo '<a href="', $scripturl, '?action=dxrecent;style=full;type=last">Topics - Last 50 </a><br />';
echo '<a href="', $scripturl, '?action=dxrecent;style=full;type=hours">Topics - Last 24 hrs</a><br />';
echo '<a href="', $scripturl, '?action=dxrecent;style=full;type=notify">Topics - You\'re Watching</a><br />';
echo '<a href="', $scripturl, '?action=dxrecent;style=full;type=bookmark">Topics - You\'ve Bookmarked</a><br />';
if (in_array(13, $user_info['groups'])) {
echo '<a href="', $scripturl, '?action=dxrecent;style=full;type=unreplied">Topics - Unreplied</a><br />';
}

// Admin only
if ($user_info['is_admin']) {
echo '<a href="', $scripturl , '?action=admin;area=viewmembers;sa=browse;type=activate', '">', sprintf($txt['admin_browse_awaiting_activate'], $context['awaiting_activation']), '</a><br />';
}




The custom action in question in this case is "dxrecent".  Would someone be able to tell me how to create this action from seeing how it will be used?
SMF 2.0.1
SimplePortal 2.3.3

eyo

January 03, 2011, 08:39:13 AM #527 Last Edit: January 03, 2011, 09:03:48 AM by eyo
ok i tried putting a url in the html headers and i noticed the title became a button and went to the action(webpage) i wanted it to, what do i put in the action url?     "Action URLs may only contain letters, numbers and underscores." i keep getting this argh i keep getting taken to the index page asldfksd;kfhasofskodf

eyo

how does one put a sub action? can anyone here give an exampe?

cloksin

SMF 2.0.1
SimplePortal 2.3.3

Andrew94©

Quote from: eyo on January 03, 2011, 07:58:27 PM
how does one put a sub action? can anyone here give an exampe?

Go to Custom Actions under features and options. You should there see:
Action Name | Type | Sub-Actions | Enabled | Modify

There will be a number (0+) underneath Sub-Actions, click it to make your sub-action for the primary action.

eyo

i dont see any sub-actions option anywhere only actions :(

Phat^Trance

does this mod allow only admins to add the bbc code?
Daily Mobile Blog:  http://dailymobile.se/
Daily iPhone Blog: http://dailyiphoneblog.com/
Daily Mobile forum: http://forum.dailymobile.se/

kingkingston

had this problem

Fatal error: Cannot redeclare template_show_custom_action() (previously declared in /home/nbathrea/public_html/Sources/Load.php(2144) : eval()'d code:2155) in /home/nbathrea/public_html/Sources/Load.php(2144) : eval()'d code on line 2296


NanoSector

Quote from: kingkingston on January 24, 2011, 05:14:02 AM
had this problem

Fatal error: Cannot redeclare template_show_custom_action() (previously declared in /home/nbathrea/public_html/Sources/Load.php(2144) : eval()'d code:2155) in /home/nbathrea/public_html/Sources/Load.php(2144) : eval()'d code on line 2296
Can you post your Load.php file, please?
My Mods / Mod Builder - A tool to easily create mods / Blog
"I've heard from a reliable source that the Answer is 42. But, still no word on what the question is."

Masterd

No. That's an evaluation error.

NanoSector

Quote from: Masterd on January 30, 2011, 05:34:31 AM
No. That's an evaluation error.
So? It's still an error that needs to be fixed.
My Mods / Mod Builder - A tool to easily create mods / Blog
"I've heard from a reliable source that the Answer is 42. But, still no word on what the question is."

Biology Forums

Can anyone tell me how I can embed another website within the code space? Would I use "html" and what code would I have to use?

Rumbaar

Quote from: shuban on April 18, 2011, 10:05:12 PM
Can anyone tell me how I can embed another website within the code space? Would I use "html" and what code would I have to use?
Well that's basic HTML knowledge that is beyond the scope of mod support here.  But you can use an iframe.  It can also depend on the target site, they might have code specific for embedding their content.
"An important reward for a job well done is a personal sense of worthwhile achievement."


[ Themes ]

Biology Forums

I don't believe this, you guys are php gurus and you no one can give me instructions on how to embed another website into the space provided? :o :-[

Advertisement: