Magento success page order number not showing - php

I have a simple question, what could cause this:
At magento success page there are no order number
Its just empty, what could cause this problem?
Order id are loaded by this line
$this->escapeHtml($this->getOrderId())
Code are loaded by manabee ordershare module.
Also this shop have many modules and code changes.
So I need as many as possible ways you can suggest why this is happening. I will check them all.

Meanbee_OrderShare_Block_Ordershare extends Mage_Checkout_Block_Onepage_Success so it should work as the standard success page block. The getOrderId metod comes from Mage_Checkout_Block_Onepage_Success. I recomend you check the exception.log, system.log and php error log, maybe you have an error. I allways recomend to read core files, then you will know how it works.
I think that you should check what you have in chechout session at first.

Related

Joomla and K2 Soft404 errors

We are using Joomla for a public site and we are getting a ton of soft 404 errors that all look similar to
/?option=com_k2&view=itemlist&task=user&id=xxx
where xxx = some numeric id. Obviously this is some soft of spamming but how do I turn it off in Joomla/K2?
I'm not particularly Joomla oriented but this seems a task I should be able to accomplish if I can get an idea of "where" to fix the code. The page shows a warning instead of an error
Warning
JUser: :_load: Unable to load user with ID: 35414
so it seems the "page" is actually there but with no content. I'm guessing some internal handler is spitting this dynamic content out but I want to return 404 in this case. Any ideas would be appreciated.
I'm trying to understand the nature of your problem. What do you mean with "Soft 404" errors? Do you have 404 errors or not?
On my K2 websites, I have sometimes "visitors" who try to find holes in K2. I then have many, many accesses of the same page. These visitors try to post comments or somethings else on the articles or user profiles.
Is this a similar thing that is happening on your site?
Is there a (Joomla) user on your site with ID 35414? If not, you can be pretty sure that someone is trying to hack your site.
Is the URL always requested by the same user? You can find this in the log files of the Apache server. In such cases I add a "deny from" statement to my .htaccess file.
In case you seriously expect a K2 related issue, I would recommend to post the issue in the K2 forum. This forum is quite knowledgeable and JoomlaWorks makes a serious effort to bring good K2 customer support.

Listing php functions that were run to load page

I'm working on a custom website and currently integrating a new section. Having done everything exactly the same as with previous sections, the behavior achieved is different.
It would be useful if I could get a list of functions run once the page loads, just like when you get them listed if there is a critical error, without having any errors.
Can't find any information on this, so any help will be appreciated!
All information that you need are in xhprof.
With that, you can check any function called in given request.

Wordpress - admin_init hook being called multiple times?

I've got a problem on my Wordpress site which I tracked down to admin_init being called twice.
I tried deactivating all the plugins and the problem goes away. I then reinstated each plugin and found which one is causing the problem.
My question is, how can I find the cause of the extra admin_init call ?
The plugin is bespoke to the site so I can't simply replace with a different plugin and it's one (blushes profusely) that I have muddled together myself.
Here's what I've got so far after doing some research on the subject...
I've added
remove_filter("wp_head", "adjacent_posts_rel_link_wp_head",10);
to the functions.php file (although this may only stop the "init" hook being called twice and not the "admin_init")?
I set up a function that sends me an email every time admin_init is called. Whilst generating the email I added the following code to it:
$backtrace = print_r(debug_backtrace(), true);
and then added $backtrace to the email text.
The first email I get has the full backtrace showing all the functions that have led up to the admin_init call originating from "admin-ajax.php". The second admin_init call email doesn't have any backtrace info at all ?
I also read that multiple calls to the init (and presumably admin_init hook) can be caused by images on the site (or other inclusions) returning a 404 error.
I have right-clicked and "inspected element" on the page to open the Firebug window and had a look through the tabs but I'm not 100% sure how to check for this. I didn't see anything odd or 404'ing under any of the tabs but if someone could just clarify the procedure for checking this I'll be able re-check for definite.
So... any other ideas as to why I'm getting this extra admin_init call and what I can check in the software to see where it's being generated?
Thanks.
I have managed to cure this problem now.
I set the following in wp-config.php:
error_reporting(E_ALL); ini_set('display_errors', 1);
This turned on strict fault reporting.
My site was immediately peppered with Notices about problems.
I systematically went through and fixed every one of them and then my original problem disappeared as well.
I'm unsure of the exact fix but that would probably be site specfiic anyway so thought I'd post this in case it helps anyone else in the future.

Modx Wayfinder different context menu only shown after refresh

I'm trying to display the main menu from other context using Wayfinder. I have the following call:
[[!Wayfinder#MainMenu? &startId=`0` &contexts=`web` &scheme=`full`]]
The problem is that the first time the page is visited, no menu is displayed. After a refresh it shows up. This happens from time to time.
I'm guessing it's some kind of cache problem but I can't figure out why it doesn't show the first time round.
Setting cacheResults to true or false doesn't seem to affect the issue.
Any help?
Thanks
This answer might come in late but you should try manually deleting the contents of core > cache via ftp or ssh. That usually does the trick when I have issues like that.

codeigniter custom 404 page not working

In codeigniter routes file there is a setting called
$route['404_override'] = 'general/not_found';
So as you can see i have given a method there. The problem is this isnt working properly. From some pages the error 404 is showing the page that ive set in the method but for some pages it is showing the default codeigniter 404 page.
So i assume that this is a bug in the framework itself. Have anyone of you faced this before? If so what is the best bypass method available to get all 404 pages return custom page?
I answered to something similar on this SO question
Basically, that's not a bug because custom re-routed error messages don't affect the calling of the core function show_404(), but only the controller-generated error message.
In order to solve this you need to make a small hack to the core show_404() inside the Exception class, and its consequent call on the show_error() function in common.php. Alternatively, follow #Eric LaForce suggestion and modify/extend the Exception class in order to work on your new directives.
Without more detail on which pages show the 404 and which do not, I am not sure, but it sounds like this person has also run into a similar situation and has devised a solution. At the very least it may point you in the correct direction. Hope it helps.

Categories