Welcome Guest, Not a member yet? Register   Sign In
Javascript not working
#1

[eluser]brucebat[/eluser]
Hi there,

I have been following the Nettuts tutorials by Jeffrey Way and was doing the CRUD tutorial. After getting the basics working succesfully I thought I would try and advance it and put it into a practical mini application.

So in my view I added a Javascript code for TinyMCE and Javascript Date picker.

However after 2 hours of pulling my hair out and screaming at my computer its still not working Sad

I have:

-Ensure the paths to the javascript files are correct
-Checked for syntax errors


Also my CSS file I created for my page is not working and the file path is correct.


This is a screenshot of what im getting.

http://imgur.com/QWctk

When I run my page source in another file outside the CI framework it works fine :S I am confused.

I should be getting something like this being displayed

http://www.thesynapticleap.org/files/tsl...ce_0_0.png

Is this a bug?

Thanks for your time.
#2

[eluser]plain jane[/eluser]
Can you please comment the Datepicker javascript and check once. That might be causing the problem.

Thanks,
ci user.
#3

[eluser]vitoco[/eluser]
you can use firebug ( NET tab ) to check the correct loading of js and css, and console tab to check for js errors
#4

[eluser]brucebat[/eluser]
This is what it says in Firebug


Localhost get Tinymce.js - 404 not found but the path is correct. Is this something to do with the URI?

Thanks for your feedback so far and I quite like this Firebug tool, cheers Lab Assistant Smile
#5

[eluser]danmontgomery[/eluser]
Are you using a relative path or an absolute one? If the path is correct, you should be able to copy the URL from firebug, paste it in your browser and get tinymce.js, is that the case?
#6

[eluser]InsiteFX[/eluser]
Create an assets folder in the root with index.php and add all folders in there for css js scripts etc.

InsiteFX
#7

[eluser]brucebat[/eluser]
Okay when I type in the absolute file path I get an access denied so Im guessing this was the problem?

Will try your suggestion right now InsiteFX.

Once again much appreciated for the responses.

-Also just on a side note could someone recommend me an approach to build my CI site? Even though Im doing all these tutorials and reading up I feel lost where to start.

I have my html template built but where do I go from there?

Thanks
#8

[eluser]InsiteFX[/eluser]
You will first need to create a plan for defining your website.

I use the 960 fluid grid for creating my templates.

So that I have a three column, two column left, tow column right and a single column this way I just load the layout that I need for the template design.

But with out a plan to define your website it will not work very well.

InsiteFX
#9

[eluser]vitoco[/eluser]
Sometimes when you copy/unzip some files inside the root directory ( or subdirectories ) it doesn't get the right permissions, so if you use linux, run this in terminal
Code:
chmod -R 0755 directory
chmod 0755 file

Saludos




Theme © iAndrew 2016 - Forum software by © MyBB