We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 11927
    • 105 Posts
    This may be a mod_security thing, but I’m not sure it is. This is on a subdomain I installed Revo on. (I installed revo on the subdomain. I’m not using another context to control the subdomain.)

    So, revo.domain.com.

    Modx 2.0.7.
    PHP 5.2.15
    System: Linux
    MySQL: 5.1.52


    I try to save a snippet.

    The saving pop-up appears, loops three times.

    Disappears, but doesn’t save.

    If I take out some of the code, it saves. I tried to figure out if it was a certain line of code, but it seemed random (at least to me it did). I’ll try to figure out if it is some code after lunch.

    My hosting doesn’t see any errors and I don’t see any errors. I remember having this same issue in Evo, but it was the mod_security issue.

    My hosting said they saw this error on the server:
    File does not exist: /home/user/public_html/connectors, referer: http://www.domain.com/revo/manager/index.php

    But shouldn’t it be looking on my subdomain? ie /home/user/public_html/revo/connectors



    Here is one snippet that won’t save:

    <?php
    // redirects to specific page
    // snippet call looks like this:
    //		[[!Forward301? &forward_link=`this-page`]]
    //		[[!Forward301? &forward_link=`other-page.html`]]
    // 		[[!Forward301? &forward_link=`http://www.domain.com/` &not_hb=`1`]]
    // in order for the redirect snippet to work, make the template for that page 'blank'
    	
    	if($not_hb == 1 || stristr($forward_link, 'http://') )
    		$url = $forward_link;
    	else
    		$url = $modx->getOption('site_url') . $forward_link;
    	
    	header('HTTP/1.1 301 Moved Permanently');
    	header( 'Location: '. $url );
    	
    	return;
      You may or may not want to use the code I write. It&#39;s probably all against the syntax rules of php and MODx. smiley

      Carpet Cleaning
      • 11927
      • 105 Posts
      I think it may be a FF thing. Because I went to IE and Chrome and it worked fine.

      Then I went back to FF and it did it again. I clear the browsers history, etc. and then logged back in and it worked finally.

      So, we’ll see what happens from here. If it keeps working or breaks again.
        You may or may not want to use the code I write. It&#39;s probably all against the syntax rules of php and MODx. smiley

        Carpet Cleaning
        • 11927
        • 105 Posts
        If you want I can report this as a bug. I just don’t want to report everything I find as a bug because it may just be that I’ve got the wrong setting flipped on somewhere.


        I think it may do this because I firebug is on?

        Firebug shows me the error I listed at the bottom.


        The error:
        POST http://revo.domain.com/connectors/element/snippet.php Aborted -- ext-base.js (line 7)
        A is undefined -- modx-min.js (line 1)
        Ext.namespace("MODx");Ext.apply(Ext,{i...iv>";}});Ext.reg("modx-msg",MODx.Msg);
          You may or may not want to use the code I write. It&#39;s probably all against the syntax rules of php and MODx. smiley

          Carpet Cleaning
          • 22303 MODX Staff
          • 10,725 Posts
          Could be, we recommend not using Firebug unless you are trying to debug something specifically. It tends to fire off multiple requests...