Author Topic: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)  (Read 31947 times)

sorian

  • Jr. Member
  • **
  • Posts: 88
Thought I would post this here for anyone else having the same problem as me.

VM: 1.1.0
JM: 1.0.15

Fresh install.

Most of the buttons in the VM admin backend don't do anything when pressed (eg: The cancel, apply, up and down arrows). No amount of chmoding helped.

I finally fixed it.

In /administrator/components/com_virtuemart/classes edit the file: mainframe.class.php starting at line 116 change:

Code: [Select]
function addScript($url, $type="text/javascript") {
static $included_scripts = array();
if( vmIsJoomla('1.0') && strstr($_SERVER['PHP_SELF'],'index3.php') ||
!vmIsJoomla() && defined('_VM_IS_BACKEND')) {
echo vmCommonHTML::scriptTag($url);
return;
}
if( isset($included_scripts[$url])) return;
else $included_scripts[$url] = 1;
$this->_scripts[] = array( 'url' => $url,
'content' => '',
'type' => $type);
}

to:

Code: [Select]
function addScript($url, $type="text/javascript") {
static $included_scripts = array();
if( vmIsJoomla('1.0') && (strstr($_SERVER['PHP_SELF'],'index3.php') || strstr($_SERVER['PHP_SELF'],'index2.php')) ||
!vmIsJoomla() && defined('_VM_IS_BACKEND')) {
echo vmCommonHTML::scriptTag($url);
return;
}
if( isset($included_scripts[$url])) return;
else $included_scripts[$url] = 1;
$this->_scripts[] = array( 'url' => $url,
'content' => '',
'type' => $type);
}

Hope this helps some people save some hair.

[edit]Also fixes tabs in the admin area.[/edit]

johnjames84

  • Beginner
  • *
  • Posts: 24
Hi,

I still get this error on IE. Pls advise. I am attaching the screenshot and mainframe.class.php.

Please advise.

Thanks
James NT

[attachment cleanup by admin]

johnjames84

  • Beginner
  • *
  • Posts: 24
Some help plsssssssssss


-James

sorian

  • Jr. Member
  • **
  • Posts: 88
Not sure what to sya. The changes worked great for me.

johnjames84

  • Beginner
  • *
  • Posts: 24
Hi,

Thanks for all help. I myself figured out the solution. This is an installation problem. The .js files in extjs2 in /components/com_virtuemat...... folder has got corrupted. I replaced all the files in this folder - this solved the issue.

The another problem I have go now is, when I go to "Add Image / File" page in the administrator side I get the JS error as "Ext is undefined" also the "Save" button does not work and throws this error "document.adminForm.ajax_request is null or an object" - please advice - is there any fix for this?? The "Apply" button on this page works fine.

Thanks
James

ReJigged

  • Jr. Member
  • **
  • Posts: 82
I'm getting the same.

Both on a live site and on my development server locally.

Have tried solution above and performed a fresh install to get same problem.

VM 1.1.1
J! 1.5.3
PHP 4.4.8 (5.2.5 on local)

Firebug gives this error when loading add image/file page

Ext is not defined
http://localhost/cog/administrator/index.php?option=com_virtuemart
Line 774

I'm trying to figure out a solution but if anyone has one already then please let me know.

tetsuo

  • Beginner
  • *
  • Posts: 5
Thanks man, it worked :)

chulian1819

  • Beginner
  • *
  • Posts: 1
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #7 on: August 26, 2008, 15:59:09 pm »
sorian master! thanks a lot!  :D

salobon

  • Jr. Member
  • **
  • Posts: 317
    • Herbolution
if you still have problem with "Ext is not defined"
in VM 1.1.3 J 1.5.10
than I fixed it with this code in /administrator/components/com_virtuemart/classes/htmlTools.class.php line 872
Code: [Select]
$vm_mainframe->addScriptDeclaration( 'Ext.BLANK_IMAGE_URL = "'.$mosConfig_live_site.'/components/'. VM_COMPONENT_NAME .'/js/extjs2/images/default/s.gif";');and add in the end code to make it look like this:
Quote
$vm_mainframe->addScriptDeclaration( 'Ext.BLANK_IMAGE_URL = "'.$mosConfig_live_site.'/components/'. VM_COMPONENT_NAME .'/js/extjs2/images/default/s.gif";', 'bottom' );
this worked for me and now will be fixed in VM 1.1.4

a.ditoppa

  • Beginner
  • *
  • Posts: 2
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #9 on: February 10, 2010, 21:06:52 pm »

I have the same problem (FAT and EXT undefined) on a fresh install of Joomla 1.5.15 and VM 1.1.4.
Could someone please suggest me how to fix this?

salobon

  • Jr. Member
  • **
  • Posts: 317
    • Herbolution
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #10 on: February 10, 2010, 21:16:39 pm »
what fixes have you tried?

patvb

  • Beginner
  • *
  • Posts: 23
    • PatVB Web Design
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #11 on: March 19, 2010, 03:17:17 am »
I am having the same issue on undefined FAT:

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB6.4; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; FDM)
Timestamp: Fri, 19 Mar 2010 02:13:43 UTC


Message: 'Fat' is undefined
Line: 668
Char: 4
Code: 0
URI: http://keepingtheromance.com/administrator/index.php


I checked the file mentioned above by salobon, but that was already fixed in this version of Virtuemart.  I am using Joomla 1.5.15 and VM 1.1.4.  This is causing strange problems.  Don't know if I should try to uninstall VM and reinstall it.  Database is huge (40K+ items).  And I can't get Paypal to work either!
Pat Vanden Bosche
PatVB Web Design
---------------------------------
www.patvb.com

Forrest

  • Full Member
  • ***
  • Posts: 1972
  • Me and my baby
    • Web Developer
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #12 on: March 19, 2010, 07:25:01 am »
This was a file permissions setting problem for patvb.

cessjulio

  • Beginner
  • *
  • Posts: 3
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #13 on: March 23, 2010, 01:50:57 am »
hey Forrest, could you tell me, what are files need permissions? thank

Forrest

  • Full Member
  • ***
  • Posts: 1972
  • Me and my baby
    • Web Developer
Re: [Solved] Admin buttons wont work (aka FAT and EXT undefined, no tabs)
« Reply #14 on: March 23, 2010, 02:49:18 am »
administrator/components/com_virtuemart
set folders to 755 recurse
set files to 644 recurse

components/com_virtuemart
set folders to 755 recurse
set files to 644 recurse