My goal is to create a custom switch including animated transitions between checked and unchecked state.
I easily achieved a default state and my switch looks as expected in both states and it changes its look when its state is changed.
Problem arises when I attach animated-selector instead of regular one.
I'm gettting an error like this:
android.view.InflateException: Binary XML file line #10: Binary XML
file line #10: Error inflating class android.widget.Switch
Caused by: android.content.res.Resources$NotFoundException: File
res/drawable/switch_track_animation_unchecked_checked.xml from
drawable resource ID #0x7f060072
at android.content.res.Resources.loadDrawableForCookie(Resources.java:2640)
Caused by: android.content.res.Resources$NotFoundException: File
res/drawable/switch_track_animated_selector.xml from drawable resource
ID #0x7f060070
I can assure that I'm properly accessing those drawables etc.
I went through invalidate caches and restart, clean build, rebuild etc. and it won't work.
View sample
<Switch
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:thumb="#drawable/switch_thumb_selector"
android:track="#drawable/switch_track_animated_selector"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
android:checked="true"
android:id="#+id/switch2"/>
switch_track_animated_selector
<animated-selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="#+id/checked"
android:drawable="#drawable/switch_bckg_on"
android:state_checked="true"/>
<item android:id="#+id/unchecked"
android:drawable="#drawable/switch_bckg_off"
android:state_checked="false"/>
<transition
android:fromId="#+id/unchecked"
android:toId="#+id/checked"
android:drawable="#drawable/switch_track_animation_unchecked_checked"/>
<transition
android:fromId="#+id/checked"
android:toId="#+id/unchecked"
android:drawable="#drawable/switch_track_animation_checked_unchecked"/>
</animated-selector>
switch_bckg_on.xml
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="#00B05A"/>
<stroke android:width="1dp" android:color="#00B05A" />
<corners android:radius="180dp"/>
<padding android:left="0dp" android:top="0dp" android:right="0dp" android:bottom="0dp" />
</shape>
switch_bckg_off.xml
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="#F1F1F1"/>
<stroke android:width="1dp" android:color="#E0E0E0" />
<corners android:radius="180dp"/>
<padding android:left="0dp" android:top="0dp" android:right="0dp" android:bottom="0dp" />
</shape>
switch_track_animation_checked_unchecked.xml
<?xml version="1.0" encoding="utf-8"?>
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:drawable="#drawable/switch_bckg_on">
<target android:name="android:drawable">
<aapt:attr name="android:animation">
<objectAnimator
android:duration="#android:integer/config_shortAnimTime"
android:interpolator="#android:interpolator/accelerate_decelerate"
android:propertyName="strokeColor"
android:valueFrom="#A0A0A0"
android:valueTo="#1E9618"
android:valueType="intType" />
</aapt:attr>
</target>
</animated-vector>
switch_track_animation_unchecked_checked.xml
<?xml version="1.0" encoding="utf-8"?>
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:drawable="#drawable/switch_bckg_off">
<target android:name="android:drawable">
<aapt:attr name="android:animation">
<objectAnimator
android:duration="#android:integer/config_shortAnimTime"
android:interpolator="#android:interpolator/accelerate_decelerate"
android:propertyName="strokeColor"
android:valueFrom="#A0A0A0"
android:valueTo="#1E9618"
android:valueType="intType"/>
</aapt:attr>
</target>
</animated-vector>
I also checked above approach using vector drawable instead of shape and I had the same result.
Example of vectors
ic_thumb_vector_off
<vector android:height="33dp" android:viewportHeight="300"
android:viewportWidth="300" android:width="33dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:name="background_off" android:fillColor="#FFFFFF" android:fillType="nonZero"
android:pathData="M149.926,149.926m-149.176,0a149.176,149.176 0,1 1,298.352 0a149.176,149.176 0,1 1,-298.352 0"
android:strokeAlpha="0.1" android:strokeColor="#000000" android:strokeWidth="0.5"/>
<path android:name="icon_off" android:fillColor="#9B9B9B" android:fillType="evenOdd"
android:pathData="M166.88,146.104C166.13,145.354 166.13,144.228 166.88,143.478L195.019,115.339C195.77,114.588 196.145,113.463 196.145,112.712C196.145,111.962 195.77,110.836 195.019,110.086L189.767,104.833C189.016,104.083 187.891,103.708 187.14,103.708C186.015,103.708 185.264,104.083 184.514,104.833L156.375,132.972C155.624,133.723 154.499,133.723 153.748,132.972L125.609,104.833C124.859,104.083 123.733,103.708 122.983,103.708C122.233,103.708 121.107,104.083 120.357,104.833L115.104,110.086C114.354,110.836 113.979,111.962 113.979,112.712C113.979,113.463 114.354,114.588 115.104,115.339L143.243,143.478C143.994,144.228 143.994,145.354 143.243,146.104L115.104,174.243C114.354,174.993 113.979,176.119 113.979,176.869C113.979,177.62 114.354,178.745 115.104,179.496L120.357,184.748C121.107,185.499 122.233,185.874 122.983,185.874C123.733,185.874 124.859,185.499 125.609,184.748L153.748,156.609C154.499,155.859 155.624,155.859 156.375,156.609L184.514,184.748C185.264,185.499 186.39,185.874 187.14,185.874C187.891,185.874 189.016,185.499 189.767,184.748L195.019,179.496C195.77,178.745 196.145,177.62 196.145,176.869C196.145,176.119 195.77,174.993 195.019,174.243L166.88,146.104Z"
android:strokeColor="#00000000" android:strokeWidth="1"/>
</vector>
ic_thumb_vector_on
<vector android:height="33dp" android:viewportHeight="302"
android:viewportWidth="302" android:width="33dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:name="background_on" android:fillColor="#FFFFFF" android:fillType="nonZero"
android:pathData="M151,151m-150.25,0a150.25,150.25 0,1 1,300.5 0a150.25,150.25 0,1 1,-300.5 0"
android:strokeAlpha="0.1" android:strokeColor="#000000" android:strokeWidth="0.5"/>
<path android:name="icon_on" android:fillColor="#00B05A" android:fillType="evenOdd"
android:pathData="M105.523,153.198C104.806,152.5 104.448,151.453 104.448,150.754C104.448,150.056 104.806,149.009 105.523,148.31L110.536,143.422C111.968,142.026 114.117,142.026 115.549,143.422L115.907,143.772L135.602,164.371C136.318,165.069 137.393,165.069 138.109,164.371L186.093,115.841L186.451,115.841C187.883,114.444 190.032,114.444 191.464,115.841L196.477,120.728C197.91,122.125 197.91,124.22 196.477,125.616L139.183,183.573C138.467,184.272 137.751,184.621 136.676,184.621C135.602,184.621 134.886,184.272 134.17,183.573L106.239,154.246L105.523,153.198Z"
android:strokeColor="#00000000" android:strokeWidth="1"/>
</vector>
Maybe I/m missing something in gradle file?
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
android {
compileSdkVersion 28
defaultConfig {
applicationId "...customswitch"
minSdkVersion 22
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.appcompat:appcompat:1.0.2'
implementation 'androidx.core:core-ktx:1.0.2'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test:runner:1.2.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}
I expect this view to load and not to throw an error on view init.
Your issue is that switch_track_animation_unchecked_checked.xml and switch_track_animation_checked_unchecked.xml are animated VectorDrawables, and these animate static VectorDrawable states. You are trying to animate ShapeDrawable, and not VectorDrawable and that's what is causing the exception, I think.
You need to replace switch_bckg_on.xml and switch_bckg_off.xml with <vector>...</vector> implementations to animate them from within an <animated-vector>...</animated-vector> block.
Alternatively you could replace the AnimatedVectorDrawables with StateListAnimator, although I'm not sure that will actually be able to do what you're trying to achieve here.
It seems like your switch_track_animated_selector does not have some default state without any id. You may try to add this state. This helped me in a similar situation
I try to use libxmljs with nodejs.
In my sample I want to use the xi:include.
<ord:order xmlns:ord="http://example.org/ord"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://example.org/ord chapter04ord1.xsd"
xmlns:xi="http://www.w3.org/2001/XInclude">
<number>123ABBCC123</number>
<customer>
<name>Priscilla Walmsley</name>
<number>15466</number>
</customer>
<items>
<xi:include href="/Users/mar/ws_e/libxml/test/resources/chapter5prod.xml" />
</items>
</ord:order>
include File:
<ord:product xmlns:ord="http://example.org/ord"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://example.org/ord chapter04ord1.xsd">
<number>557</number>
<name>Short-Sleeved Linen Blouse</name>
<size system="US-DRESS">10</size>
<color value="blue"/>
</ord:product>
This is my code:
var xsdDoc = libxml.parseXml(schemaSource);
var xmlDocValid = libxml.parseXml(docSource);
var xmlDocInvalid = libxml.parseXml(xml_invalid);
xmlDocValid.validate(xsdDoc);
console.dir(xmlDocValid);
console.dir(xmlDocValid.validationErrors);
Then I get the error:
Document {
errors: [],
validationErrors:
[ { Error: Element '{http://www.w3.org/2001/XInclude}include': This element is not expected. Expected is ( product ).
So my question is how to use the x:include right at libxmljs?
Kind regards
Markus
How to use AlloyUI 3.0.1 within a portlet in Liferay 6.2 The version without losing functionality in the rest of the portal.
happens whether or not I import the following
<script src="http://cdn.alloyui.com/3.0.1/aui/aui-min.js"></script>
<link href="http://cdn.alloyui.com/3.0.1/aui-css/css/bootstrap.min.css" rel="stylesheet"></link>
this is my code...
liferay-portlet.xml
<?xml version="1.0"?>
<!DOCTYPE liferay-portlet-app PUBLIC "-//Liferay//DTD Portlet Application 6.2.0//EN" "http://www.liferay.com/dtd/liferay-portlet-app_6_2_0.dtd">
<liferay-portlet-app>
<portlet>
<portlet-name>example-input-alert</portlet-name>
<icon>/icon.png</icon>
<header-portlet-css>/css/main.css</header-portlet-css>
<header-portlet-css>http://cdn.alloyui.com/3.0.1/aui-css/css/bootstrap.min.css</header-portlet-css>
<header-portlet-javascript>http://cdn.alloyui.com/3.0.1/aui/aui-min.js</header-portlet-javascript>
<footer-portlet-javascript>/js/main.js</footer-portlet-javascript>
<css-class-wrapper>example-input-alert-portlet</css-class-wrapper>
</portlet>
<role-mapper>
<role-name>administrator</role-name>
<role-link>Administrator</role-link>
</role-mapper>
<role-mapper>
<role-name>guest</role-name>
<role-link>Guest</role-link>
</role-mapper>
<role-mapper>
<role-name>power-user</role-name>
<role-link>Power User</role-link>
</role-mapper>
<role-mapper>
<role-name>user</role-name>
<role-link>User</role-link>
</role-mapper>
</liferay-portlet-app>
Resource "http://cdn.alloyui.com/3.0.1/aui/aui-min.js" not found.
view.jsp
<%# taglib uri="http://java.sun.com/portlet_2_0" prefix="portlet"%>
<portlet:defineObjects />
<div id="myAlert"></div>
<script>
YUI()
.use(
'aui-alert',
function(Y) {
new Y.Alert(
{
animated : true,
bodyContent : 'Thank You Mario! But Our Princess Is In That Castle!',
boundingBox : '#myAlert',
closeable : true,
cssClass : 'alert-warning',
destroyOnHide : false,
duration : 1,
render : true
});
});
</script>
before
after
some elements disappear portal and portlets lose other functionality...
thx !
This is the response of staff Liferay...
You need to import the library using liferay-portlet.xml in your portlet:
<header-portlet-css>http://cdn.alloyui.com/3.0.1/aui-css/css/bootstrap.min.css</header-portlet-css>
<header-portlet-javascript>http://cdn.alloyui.com/3.0.1/aui/aui-min.js</header-portlet-javascript>
See the docs (It's explained at the bottom)
I am trying to archive a build for distribution to the app store but during the archive process I keep getting an exception popup from Xamarin Studio saying the following:
"An error has occurred - Failed to archive app bundle. An empty string is not considered a valid value"
The exception occurs when it is signing the application:
'System.ArgumentException: An empty string is not considered a valid value.
at System.Enum.Parse (System.Type enumType, System.String value, Boolean ignoreCase) [0x00081] in /private/tmp/source/bockbuild-xamarin/profiles/mono-mac-xamarin/build-root/mono-3.2.3/mcs/class/corlib/System/Enum.cs:523
at System.Enum.Parse (System.Type enumType, System.String value) [0x00000] in /private/tmp/source/bockbuild-xamarin/profiles/mono-mac-xamarin/build-root/mono-3.2.3/mcs/class/corlib/System/Enum.cs:453
at Xamarin.MacDev.PropertyListFormat+XmlFormat+Context.ReadObjectHead () [0x00001] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/Xamarin.MacDev/PListObject.cs:1737
at Xamarin.MacDev.PropertyListFormat+XmlFormat+Context..ctor (System.Xml.XmlReader reader) [0x0000f] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/Xamarin.MacDev/PListObject.cs:1726
at Xamarin.MacDev.PropertyListFormat+XmlFormat.StartReading (System.IO.Stream input) [0x0008e] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/Xamarin.MacDev/PListObject.cs:1702
at Xamarin.MacDev.PropertyListFormat.CreateReadContext (System.IO.Stream input) [0x00019] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/Xamarin.MacDev/PListObject.cs:1070
at Xamarin.MacDev.PDictionary.FromFile (System.String fileName, System.Boolean& isBinary) [0x00026] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/Xamarin.MacDev/PListObject.cs:664
at Xamarin.MacDev.PDictionary.FromFile (System.String fileName) [0x00004] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/Xamarin.MacDev/PListObject.cs:653
at MonoDevelop.IPhone.IPhoneProject.Archive (IProgressMonitor monitor, MonoDevelop.Projects.DotNetProjectConfiguration conf) [0x00111] in /Users/builder/data/lanes/monodevelop-lion-monodevelop-4.0.13-branch/07afec66/source/md-addins/MonoDevelop.IPhone/MonoDevelop.IPhone/Project/IPhoneProject.cs:384'
Heres my bin\AppStore\iPhone\AppName.app\Info.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BuildMachineOSBuild</key>
<string>11G63b</string>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
<string>ANet</string>
<key>CFBundleExecutable</key>
<string>ANetMobile</string>
<key>CFBundleIconFiles</key>
<array>
<string>logo_57.png</string>
<string>logo_114.png</string>
<string>logo_120.png</string>
</array>
<key>CFBundleIdentifier</key>
<string>com.anet.anmobile</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>ANetMobile</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleResourceSpecification</key>
<string>ResourceRules.plist</string>
<key>CFBundleShortVersionString</key>
<string>1.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleSupportedPlatforms</key>
<array>
<string>iPhoneOS</string>
</array>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>DTCompiler</key>
<string>com.apple.compilers.llvm.clang.1_0</string>
<key>DTPlatformBuild</key>
<string>9B176</string>
<key>DTPlatformName</key>
<string>iphoneos</string>
<key>DTPlatformVersion</key>
<string>5.1</string>
<key>DTSDKBuild</key>
<string>9B176</string>
<key>DTSDKName</key>
<string>iphoneos5.1</string>
<key>DTXcode</key>
<string>0440</string>
<key>DTXcodeBuild</key>
<string>4F250</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>MinimumOSVersion</key>
<string>4.3</string>
<key>UIDeviceFamily</key>
<array>
<integer>1</integer>
</array>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv6</string>
</array>
<key>UIStatusBarTintParameters</key>
<dict>
<key>UINavigationBar</key>
<dict>
<key>Style</key>
<string>UIBarStyleDefault</string>
<key>TintColor</key>
<dict>
<key>Blue</key>
<real>1</real>
<key>Green</key>
<real>0.0</real>
<key>Red</key>
<real>0.0</real>
</dict>
<key>Translucent</key>
<false/>
</dict>
</dict>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>
Are all of your fields filled in on the project options? Make sure you have app name filled in. I archived my ad-hoc distribution app this week with no problems.
Try to fix this first:
<key>CFBundleSignature</key>
<string>????</string>
in your project options:
Try to set a valid bundle identifier.
Then, in order to build for the AppStore, you'll have to register this BundleIdentifier on Apple website
Xamarin has confirmed this is a bug in Studio, and will be fixed in 4.0.14 hotfix release.
I'm trying to add to the field list of the categories a new text field called "website_url".
I found many tutorials but none works on magento 1.7.
I created a new module as following :
-code\local\SaponeWebConcept\CategoriesAttributes\sql\categoriesattributes_setup\mysql4-install-0.1.0.php :
<?php
$installer = $this;
$installer->startSetup();
$installer->addAttribute('catalog_category', 'website_url', array(
'type' => 'text',
'backend' => '',
'frontend' => '',
'label' => 'Lien du site',
'input' => 'text',
'class' => '',
'source' => '',
'global' => 0,
'visible' => 1,
'required' => 0,
'user_defined' => 0,
'default' => '',
'searchable' => 0,
'filterable' => 0,
'comparable' => 0,
'visible_on_front' => 0,
'unique' => 0,
'position' => 1,
));
$installer->endSetup();
-code\local\SaponeWebConcept\CategoriesAttributes\etc\config.xml
<?xml version="1.0"?>
<config>
<modules>
<SaponeWebConcept_CategoriesAttributes>
<version>0.1.0</version>
</SaponeWebConcept_CategoriesAttributes>
</modules>
<global>
<resources>
<categoriesattributes_setup>
<setup>
<module>SaponeWebConcept_CategoriesAttributes</module>
<class>Mage_Catalog_Model_Resource_Eav_Mysql4_Setup</class>
</setup>
<connection>
<use>core_setup</use>
</connection>
</categoriesattributes_setup>
</resources>
</global>
</config>
And my module is correctly activated by this :
<SaponeWebConcept_CategoriesAttributes>
<active>true</active>
<codePool>local</codePool>
</SaponeWebConcept_CategoriesAttributes>
But when I access my category editing, I don't see any new field.
What am I doing wrong ? The module is supposed to work immediatly if the cache is off, right ?
Thanks in advance.
I had the same issue. This is how I solved it:
app/code/local/yourmodulename/sql/yourcustomattribute_setup/mysql4-upgrade-0.0.9-0.1.3.php
<?php
$installer = $this;
$installer->startSetup();
$installer->addAttribute("catalog_category", "your_attribute", array(
"type" => "varchar",
"backend" => "",
"frontend" => true,
"label" => "Your Attribute",
"input" => "text",
"class" => "",
"source" => "",
"global" => Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_GLOBAL,
"visible" => true,
"required" => false,
"user_defined" => false,
"default" => "",
"searchable" => false,
"filterable" => false,
"comparable" => false,
"visible_on_front" => true,
"unique" => true,
"note" => ""
));
$installer->endSetup();
app/code/local/yourmodulename/etc/config.xml
<config>
<modules>
<Yournamespace_Yourmodulename>
<version>0.1.3</version>
</Yournamespace_Yourmodulename>
</modules>
<frontend>
<routers>
<yourmodulename>
<use>standard</use>
<args>
<module>Yournamespace_Yourmodulename</module>
<frontName>categoryattribute</frontName>
</args>
</yourmodulename>
</routers>
<category>
<collection>
<attributes>
<yourmodulename />
</attributes>
</collection>
</category>
<layout>
<updates>
<yourmodulename>
<file>categoryattribute.xml</file>
</yourmodulename>
</updates>
</layout>
</frontend>
<global>
<helpers>
<yourmodulename>
<class>Yournamespace_Yourmodulename_Helper</class>
</yourmodulename>
</helpers>
<blocks>
<yourmodulename>
<class>Yournamespace_Yourmodulename_Block</class>
</yourmodulename>
</blocks>
<models>
<yourmodulename>
<class>Yournamespace_Yourmodulename_Model</class>
<resourceModel>categoryattribute_mysql4</resourceModel>
</yourmodulename>
</models>
<resources>
<yourmodulenamee_setup>
<setup>
<module>Yournamespace_Yourmodulename</module>
<class>Mage_Catalog_Model_Resource_Eav_Mysql4_Setup</class>
</setup>
<connection>
<use>core_setup</use>
</connection>
</yourmodulename_setup>
<yourmodulename_write>
<connection>
<use>core_write</use>
</connection>
</yourmodulename_write>
<yourmodulename_read>
<connection>
<use>core_read</use>
</connection>
</yourmodulename_read>
</resources>
</global>
</config>
app/etc/modules/Your_modulename.xml
<?xml version="1.0"?>
<config>
<modules>
<Yournamespace_Yourmodulename>
<active>true</active>
<codePool>local</codePool>
<version>0.1.3</version>
</Yournamespace_Yourmodulename>
</modules>
</config>
Check you database to see if the sql has been installed under "Eav Attribute"
You custom category attribute should now be showing in the frontend!!!!
Now all you need to do is show the attribute on the frontened using:
<?php echo $_product->getYourattributeid(); ?>
For those who have this kind of problems my solution in MAGENTO 1.8 whas only make sure that VERSION tag is setted.. if you dont put it cause mysql4-install-0.0.1.php never is called .
<config>
<modules>
<Yournamespace_Yourmodulename>
<active>true</active>
<codePool>local</codePool>
<version>0.0.1</version>
</Yournamespace_Yourmodulename>
</modules>
</config>