News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Custom Action Mod

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

Previous topic - Next topic

ameo

1.
hey, does anyone know why I get this error:

Not Acceptable
An appropriate representation of the requested resource /forum/index.php could not be found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

when I'm trying to delete a block. And can it be deleted manually, if nothing helps.

2. Also, why, when I set block to be php, and input this : <?php include("/home/ameo/public_html/pulse/blocks/skyline.html"); ?>
I get Parse error: syntax error, unexpected '<' in /home/ameo/public_html/forum/Sources/Load.php(1733) : eval()'d code(9) : eval()'d code on line 1
antechinus:
QuoteIf you are dying for a solution it may be wise to seek medical attention.
Get some Awesome Smileys for your forum

|±(ಠ_ಠ
)±|

L'AltroWeb

Quote from: Dark-Wolf on March 30, 2010, 05:17:06 PM
I've maked a php custom action and i've test to use some string from "index.english.php" but not work.
Is there any way to fix this problem?
-
Edit: ok, i've changed, in CustomAction.template.php
// Show a custom action.
function template_main()
{
global $context;

to:
// Show a custom action.
function template_main()
{
global $context, $txt;

and now i can use $txt['string_from_indext_emplate'] ;)

KensonPlays

I would love this, but the buttons on the page have no text in it, for one, and when I click them nothing happens.

Norv

Kcmartz: Please, try the last version.

Dark-Wolf: Sorry for the delay. Good to see you worked it out, and thank you very much for sharing it. :)

ameo: it sounds like mod_security is installed on your host's Apache server. Maybe contacting them and telling them the URL causing the problem would help them identifying the rule and eventually making an exception.
To-do lists are for deferral. The more things you write down the later they're done... until you have 100s of lists of things you don't do.

File a security report | Developers' Blog | Bug Tracker


Also known as Norv on D* | Norv N. on G+ | Norv on Github

Joe_Dean

#504
Nice mod! But where does it store the code? MySQL? Or does it create a file somewhere?

I just can't stand having to add PHP code to a tiny text box rather than editing a file (which would be easier). Any alternatives?


EDIT: I'll just call to a function specific to each action inside the code box and create a php file with all the functions (hence editing files instead of using these small text boxes lol)

KensonPlays

When will this have support for RC4? I am waiting until my main modifications (the important ones) have RC4 support before I upgrade. This is holding me back.

KensonPlays

Sorry for double post. I installed no errors, and looks fine on RC4!!

Norv

Thank you for the feedback. I didn't have time to test it too, but will do.
To-do lists are for deferral. The more things you write down the later they're done... until you have 100s of lists of things you don't do.

File a security report | Developers' Blog | Bug Tracker


Also known as Norv on D* | Norv N. on G+ | Norv on Github

KensonPlays


KensonPlays

#509
********n phone. please delete all but post above this**

KensonPlays

#510
**please delete, see below post**

KensonPlays

#511
**please delete, my phone sometimes double submits forms**

Robert.


Mike Stowe

Hi,

I really love this mod!!! Its making my life so much easier!

I'm having some trouble linking to a photo gallery though. I don't know any php at all and somehow I managed to get this photo gallery installed but I can't figure out how to link to it through the mod.



http://www.wararmada.com/screenshots/index.php



The screenshots folder is in the public-html folder with the rest of my SMF stuff.

Thanks for any help.

Mike Stowe

Sorry another question.

If i want to display a custom page as the home page do i need to instill the forums in a sub folder?

Thanks

inflatablemouse

#515
Never mind, I stopped using this.

Mike Stowe

How do i add sub actions?

I'm trying to add dropdown links to my overvew button.

I'm going to

http://www.wararmada.com/smf/index.php?action=overview;sa=""""The name I want to use on the button"""""".

and the page is not found.

I've tried adding a page using them info but it tells me

QuoteAction URLs may only contain letters, numbers and underscores.

The code i've been trying to use to add the sub action is

overview;sa=corpmerger

Thanks for the help!

NanoSector

works fine in RC4. No need to emulate, either.
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."

Shalika

#518
I installed it on 1.1.12 .. it passed all tests and got installed.
Now I don't see any link in Features and Options other than

Basic Features | Layout and Options | Karma

How to fix this ?


Oh I'm sorry.. I reinstalled and got it working.

eyo

my html and bbc stuff have disappeared lately for some reason i dunno(i checked everything in the forum posting admin section)

im afraid of installing this as a "solution" for my current problem, but can this help? btw i got this during install, is this a green light?(rc4)

1.    Adapt Database    install.php    
   2.    Extract File    ./Sources/CustomAction.php    
   3.    Extract File    ./Themes/default/CustomAction.template.php    
*    4.    Execute Modification    ./Sources/ManageSettings.php    Test successful
      1.    Replace    ./Sources/ManageSettings.php    Test successful
      2.    Replace    ./Sources/ManageSettings.php    Test successful
      3.    Add Before    ./Sources/ManageSettings.php    Test successful
*    5.    Execute Modification    ./Sources/Admin.php    Test successful
      1.    Add Before    ./Sources/Admin.php    Test successful
*    6.    Execute Modification    ./Themes/default/languages/Modifications.english.php    Test successful
      1.    Add Before    ./Themes/default/languages/Modifications.english.php    Test successful
   7.    Execute Modification    ./Themes/default/languages/Modifications.german.php    Skipping file
   8.    Execute Modification    ./Themes/default/languages/Modifications.german-utf8.php    Skipping file
*    9.    Execute Modification    ./Sources/Subs.php    Test successful
      1.    Replace    ./Sources/Subs.php    Test successful
*    10.    Execute Modification    ./index.php    Test successful
      1.    Replace    ./index.php    Test successful
*    11.    Execute Modification    ./Themes/default/Admin.template.php    Test successful

Advertisement: