ajax e dom

This commit is contained in:
2014-12-07 19:33:49 +01:00
parent c30036a3bc
commit 7f21febb90
13 changed files with 423 additions and 64 deletions

3
.idea/encodings.xml generated
View File

@@ -1,4 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" /> <component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
</project> </project>

3
.idea/misc.xml generated
View File

@@ -1,4 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ProjectRootManager" version="2" /> <component name="ProjectRootManager" version="2" />
</project> </project>

3
.idea/modules.xml generated
View File

@@ -5,4 +5,5 @@
<module fileurl="file://$PROJECT_DIR$/.idea/unisa 14-15 tsw.iml" filepath="$PROJECT_DIR$/.idea/unisa 14-15 tsw.iml" /> <module fileurl="file://$PROJECT_DIR$/.idea/unisa 14-15 tsw.iml" filepath="$PROJECT_DIR$/.idea/unisa 14-15 tsw.iml" />
</modules> </modules>
</component> </component>
</project> </project>

View File

@@ -5,4 +5,5 @@
<orderEntry type="inheritedJdk" /> <orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" /> <orderEntry type="sourceFolder" forTests="false" />
</component> </component>
</module> </module>

3
.idea/vcs.xml generated
View File

@@ -3,4 +3,5 @@
<component name="VcsDirectoryMappings"> <component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" /> <mapping directory="$PROJECT_DIR$" vcs="Git" />
</component> </component>
</project> </project>

250
.idea/workspace.xml generated
View File

@@ -2,10 +2,16 @@
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="f405bcb8-0de2-4a3f-bdf4-b8ba34c0c82e" name="Default" comment=""> <list default="true" id="f405bcb8-0de2-4a3f-bdf4-b8ba34c0c82e" name="Default" comment="">
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/encodings.xml" afterPath="$PROJECT_DIR$/.idea/encodings.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/misc.xml" afterPath="$PROJECT_DIR$/.idea/misc.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/modules.xml" afterPath="$PROJECT_DIR$/.idea/modules.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/unisa 14-15 tsw.iml" afterPath="$PROJECT_DIR$/.idea/unisa 14-15 tsw.iml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/vcs.xml" afterPath="$PROJECT_DIR$/.idea/vcs.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
</list> </list>
<ignored path="unisa 14-15 tsw.iws" /> <ignored path="unisa 14-15 tsw.iws" />
<ignored path=".idea/workspace.xml" /> <ignored path=".idea/workspace.xml" />
<ignored path=".idea/dataSources.local.xml" />
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" /> <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
<option name="TRACKING_ENABLED" value="true" /> <option name="TRACKING_ENABLED" value="true" />
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
@@ -26,44 +32,46 @@
</component> </component>
<component name="FileEditorManager"> <component name="FileEditorManager">
<leaf> <leaf>
<file leaf-file-name="js_20.html" pinned="false" current-in-tab="true"> <file leaf-file-name="dom1.html" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/js_20.html"> <entry file="file://$PROJECT_DIR$/dom1.html">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.33333334" vertical-offset="0" max-vertical-offset="918"> <state vertical-scroll-proportion="0.5704698" vertical-offset="0" max-vertical-offset="596">
<caret line="18" column="24" selection-start-line="18" selection-start-column="24" selection-end-line="18" selection-end-column="24" /> <caret line="20" column="55" selection-start-line="20" selection-start-column="55" selection-end-line="20" selection-end-column="55" />
<folding> <folding />
<element signature="e#245#394#0" expanded="false" />
<element signature="e#510#663#0" expanded="false" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
</file> </file>
</leaf> </leaf>
</component> </component>
<component name="FindManager">
<FindUsagesManager>
<setting name="OPEN_NEW_TAB" value="true" />
</FindUsagesManager>
</component>
<component name="Git.Settings"> <component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" /> <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
</component> </component>
<component name="IdeDocumentHistory"> <component name="IdeDocumentHistory">
<option name="CHANGED_PATHS"> <option name="changedFiles">
<list> <list>
<option value="$PROJECT_DIR$/js1.html" /> <option value="$PROJECT_DIR$/ajax.php" />
<option value="$PROJECT_DIR$/js2.html" /> <option value="$PROJECT_DIR$/ajax.html" />
<option value="$PROJECT_DIR$/js3.html" /> <option value="$PROJECT_DIR$/ajax2.php" />
<option value="$PROJECT_DIR$/js_1.html" /> <option value="$PROJECT_DIR$/ajax2.html" />
<option value="$PROJECT_DIR$/js_2.html" /> <option value="$PROJECT_DIR$/ajax_json.php" />
<option value="$PROJECT_DIR$/js_3.html" /> <option value="$PROJECT_DIR$/ajax2_json.php" />
<option value="$PROJECT_DIR$/js_7.html" /> <option value="$PROJECT_DIR$/ajax2_json.html" />
<option value="$PROJECT_DIR$/js_8.html" /> <option value="$PROJECT_DIR$/dom1.html" />
<option value="$PROJECT_DIR$/js_9.html" />
<option value="$PROJECT_DIR$/js_10.html" />
<option value="$PROJECT_DIR$/js_20.html" />
</list> </list>
</option> </option>
</component> </component>
<component name="JsGulpfileManager"> <component name="PhpServers">
<detection-done>true</detection-done> <servers>
<server host="localhost/unisa%20tsw%2014-15/" name="wamp php server" />
</servers>
</component> </component>
<component name="PhpWorkspaceProjectConfiguration" backward_compatibility_performed="true" interpreter_name="PHP" />
<component name="ProjectFrameBounds"> <component name="ProjectFrameBounds">
<option name="x" value="-8" /> <option name="x" value="-8" />
<option name="y" value="-8" /> <option name="y" value="-8" />
@@ -80,6 +88,9 @@
<ConfirmationsSetting value="1" id="Add" /> <ConfirmationsSetting value="1" id="Add" />
<ConfirmationsSetting value="0" id="Remove" /> <ConfirmationsSetting value="0" id="Remove" />
</component> </component>
<component name="ProjectReloadState">
<option name="STATE" value="0" />
</component>
<component name="ProjectView"> <component name="ProjectView">
<navigator currentView="Scope" currentSubView="Project Files" proportions="" version="1"> <navigator currentView="Scope" currentSubView="Project Files" proportions="" version="1">
<flattenPackages /> <flattenPackages />
@@ -120,7 +131,7 @@
<option name="myItemId" value="" /> <option name="myItemId" value="" />
<option name="myItemType" value="" /> <option name="myItemType" value="" />
</PATH_ELEMENT> </PATH_ELEMENT>
<PATH_ELEMENT USER_OBJECT="unisa 14-15 tsw"> <PATH_ELEMENT USER_OBJECT="unisa tsw 14-15">
<option name="myItemId" value="" /> <option name="myItemId" value="" />
<option name="myItemType" value="" /> <option name="myItemType" value="" />
</PATH_ELEMENT> </PATH_ELEMENT>
@@ -131,10 +142,10 @@
</component> </component>
<component name="PropertiesComponent"> <component name="PropertiesComponent">
<property name="WebServerToolWindowFactoryState" value="false" /> <property name="WebServerToolWindowFactoryState" value="false" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/js3.html" /> <property name="last_opened_file_path" value="$PROJECT_DIR$/ajax.php" />
<property name="HbShouldOpenHtmlAsHb" value="" /> <property name="HbShouldOpenHtmlAsHb" value="" />
<property name="recentsLimit" value="5" /> <property name="recentsLimit" value="5" />
<property name="options.lastSelected" value="configurable.group.appearance" /> <property name="options.lastSelected" value="fileTemplates" />
<property name="options.splitter.main.proportions" value="0.3" /> <property name="options.splitter.main.proportions" value="0.3" />
<property name="options.splitter.details.proportions" value="0.2" /> <property name="options.splitter.details.proportions" value="0.2" />
<property name="restartRequiresConfirmation" value="true" /> <property name="restartRequiresConfirmation" value="true" />
@@ -143,54 +154,66 @@
</component> </component>
<component name="RecentsManager"> <component name="RecentsManager">
<key name="CopyFile.RECENT_KEYS"> <key name="CopyFile.RECENT_KEYS">
<recent name="C:\wamp\www\unisa tsw 14-15" />
<recent name="F:\Codes\Html\unisa 14-15 tsw" /> <recent name="F:\Codes\Html\unisa 14-15 tsw" />
</key> </key>
</component> </component>
<component name="RunManager" selected="JavaScript Debug.test ff"> <component name="RunManager" selected="PHP Web Application.launch">
<configuration default="true" type="DartCommandLineRunConfigurationType" factoryName="Dart Command Line Application"> <configuration default="true" type="PHPUnitRunConfigurationType" factoryName="PHPUnit">
<TestRunner />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="DartUnitRunConfigurationType" factoryName="DartUnit"> <configuration default="true" type="PhpBuiltInWebServerConfigurationType" factoryName="PHP Built-in Web Server">
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="JavaScriptTestRunnerKarma" factoryName="Karma" config-file=""> <configuration default="true" type="PhpWebAppRunConfigurationType" factoryName="PHP Web Application" browser="a7bb68e0-33c0-4d6f-a81a-aac1fdb870c8" server_name="wamp php server">
<envs />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="JSTestDriver:ConfigurationType" factoryName="JsTestDriver"> <configuration default="true" type="PhpRemoteDebugRunConfigurationType" factoryName="PHP Remote Debug">
<setting name="configLocationType" value="CONFIG_FILE" /> <method />
<setting name="settingsFile" value="" /> </configuration>
<setting name="serverType" value="INTERNAL" /> <configuration default="true" type="PhpHttpRequestRunConfigurationType" factoryName="PHP HTTP Request">
<setting name="preferredDebugBrowser" value="Chrome" /> <method />
</configuration>
<configuration default="true" type="ChromiumRemoteDebugType" factoryName="Chromium Remote">
<option name="name" value="" />
<method />
</configuration>
<configuration default="true" type="PhpLocalRunConfigurationType" factoryName="PHP Console">
<method />
</configuration>
<configuration default="true" type="NodeWebKit" factoryName="Node-webkit">
<option name="name" value="" />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="JavascriptDebugType" factoryName="JavaScript Debug"> <configuration default="true" type="JavascriptDebugType" factoryName="JavaScript Debug">
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="NodeJSConfigurationType" factoryName="Node.js" working-dir=""> <configuration default="true" type="PhpBehatConfigurationType" factoryName="Behat">
<BehatRunner />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="cucumber.js" factoryName="Cucumber.js"> <configuration default="true" type="AppEnginePhpConfigurationType" factoryName="App Engine for PHP">
<option name="cucumberJsArguments" value="" />
<option name="executablePath" />
<option name="filePath" />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="js.build_tools.gulp" factoryName="Gulp.js"> <configuration default="true" type="js.build_tools.gulp" factoryName="Gulp.js">
<node-options /> <node-options />
<gulpfile /> <gulpfile />
<tasks /> <tasks />
<pass-parent-envs>true</pass-parent-envs> <pass-parent-env-vars>false</pass-parent-env-vars>
<envs /> <envs />
<method /> <method />
</configuration> </configuration>
<configuration default="false" name="test ff" type="JavascriptDebugType" factoryName="JavaScript Debug" engineId="a7bb68e0-33c0-4d6f-a81a-aac1fdb870c8" uri="http://localhost:63342/unisa 14-15 tsw/js_1.html"> <configuration default="true" type="PhpUnitRemoteRunConfigurationType" factoryName="PHPUnit on Server">
<RunnerSettings RunnerId="JavascriptDebugRunner" /> <method />
<ConfigurationWrapper RunnerId="JavascriptDebugRunner" /> </configuration>
<configuration default="false" name="launch" type="PhpWebAppRunConfigurationType" factoryName="PHP Web Application" server_name="wamp php server" start_url="/dom1.html">
<RunnerSettings RunnerId="PhpRunner" />
<ConfigurationWrapper RunnerId="PhpRunner" />
<method /> <method />
</configuration> </configuration>
<list size="1"> <list size="1">
<item index="0" class="java.lang.String" itemvalue="JavaScript Debug.test ff" /> <item index="0" class="java.lang.String" itemvalue="PHP Web Application.launch" />
</list> </list>
</component> </component>
<component name="ShelveChangesManager" show_recycled="false" /> <component name="ShelveChangesManager" show_recycled="false" />
@@ -213,21 +236,23 @@
<window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" /> <window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" /> <window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Application Servers" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" /> <window_info id="Application Servers" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.25" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" /> <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.15208334" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.3298969" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" /> <window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" /> <window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.3298969" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" /> <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" /> <window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" /> <window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" /> <window_info id="PHP-CGI Server" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="SLIDING" type="SLIDING" visible="false" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" /> <window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="SLIDING" type="SLIDING" visible="false" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" /> <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
</layout> </layout>
</component> </component>
<component name="Vcs.Log.UiProperties"> <component name="Vcs.Log.UiProperties">
@@ -251,14 +276,73 @@
<watches-manager /> <watches-manager />
</component> </component>
<component name="editorHistoryManager"> <component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/ajax.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="663">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.php">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="136" max-vertical-offset="272">
<caret line="8" column="0" selection-start-line="8" selection-start-column="0" selection-end-line="8" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="442" max-vertical-offset="663">
<caret line="26" column="0" selection-start-line="26" selection-start-column="0" selection-end-line="26" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.php">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="187">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="663">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="663">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.php">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="100">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="663">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/js_20.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="850">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/js_20.html"> <entry file="file://$PROJECT_DIR$/js_20.html">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="850"> <state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="850">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" /> <caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding>
<element signature="e#245#394#0" expanded="false" />
<element signature="e#510#663#0" expanded="false" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
@@ -355,14 +439,62 @@
</entry> </entry>
<entry file="file://$PROJECT_DIR$/js_20.html"> <entry file="file://$PROJECT_DIR$/js_20.html">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.33333334" vertical-offset="0" max-vertical-offset="918"> <state vertical-scroll-proportion="-11.769231" vertical-offset="0" max-vertical-offset="850">
<caret line="18" column="24" selection-start-line="18" selection-start-column="24" selection-end-line="18" selection-end-column="24" /> <caret line="18" column="24" selection-start-line="18" selection-start-column="24" selection-end-line="18" selection-end-column="24" />
<folding> </state>
<element signature="e#245#394#0" expanded="false" /> </provider>
<element signature="e#510#663#0" expanded="false" /> </entry>
</folding> <entry file="file://$PROJECT_DIR$/ajax.php">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="-5.230769" vertical-offset="0" max-vertical-offset="272">
<caret line="8" column="0" selection-start-line="8" selection-start-column="0" selection-end-line="8" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="-5.269231" vertical-offset="67" max-vertical-offset="663">
<caret line="12" column="0" selection-start-line="12" selection-start-column="0" selection-end-line="12" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax2.php">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="-0.0" vertical-offset="0" max-vertical-offset="289">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="16" selection-end-column="2" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax2.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="-5.923077" vertical-offset="237" max-vertical-offset="986">
<caret line="23" column="0" selection-start-line="23" selection-start-column="0" selection-end-line="23" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax2_json.php">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="-0.0" vertical-offset="0" max-vertical-offset="357">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ajax2_json.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="-0.77348995" vertical-offset="461" max-vertical-offset="1156">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/dom1.html">
<provider selected="true" editor-type-id="text-editor">
<state vertical-scroll-proportion="0.5704698" vertical-offset="0" max-vertical-offset="596">
<caret line="20" column="55" selection-start-line="20" selection-start-column="55" selection-end-line="20" selection-end-column="55" />
<folding />
</state> </state>
</provider> </provider>
</entry> </entry>
</component> </component>
</project> </project>

34
ajax.html Normal file
View File

@@ -0,0 +1,34 @@
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title></title>
</head>
<body>
<p> Ciao, Simone è gay?</p>
<p id="answer"></p>
<script>
req= new XMLHttpRequest();
req.addEventListener("load",handler,false);
req.open("GET","ajax.php",true);
req.send();
function handler(e){
document.getElementById("answer").innerHTML = req.responseText;
}
</script>
</body>
</html>

11
ajax.php Normal file
View File

@@ -0,0 +1,11 @@
<?php
/**
* Created by xgiovio.
* User: Giovanni
* Date: 05/12/2014
* Time: 13:36
*/
echo "si";
?>

53
ajax2.html Normal file
View File

@@ -0,0 +1,53 @@
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title></title>
</head>
<body>
<p> Ciao, Simone è gay?</p>
<p id="answer"></p>
<form id="form">
<input type ="text" name="nome" placeholder="Inserisci il nome" value="" />
<input type ="text" name="cognome" placeholder="Inserisci il cognome" value=""/>
<input type ="number" name="eta" min="10" max="120" placeholder="Inserisci eta" value="" />
</form>
<br>
<span id ="data"></span>
<script>
req= new XMLHttpRequest();
req.addEventListener("load",handlerload,false);
i = document.getElementsByTagName("input");
for (k=0;k< i.length;k++)
i[k].addEventListener("input",handler,false);
function handler(e){
form = new FormData(document.getElementById("form"));
req.open("POST","ajax2.php",true);
req.send(form);
document.getElementById("answer").innerHTML = req.responseText;
}
function handlerload(e){
document.getElementById("data").innerHTML = req.responseText;
}
</script>
</body>
</html>

17
ajax2.php Normal file
View File

@@ -0,0 +1,17 @@
<?php
/**
* Created by xgiovio.
* User: Giovanni
* Date: 05/12/2014
* Time: 13:36
*/
if ($_POST){
foreach ( $_POST as $key => $value){
echo $key,":",$value,";";
}
}else
echo "No data yet";
?>

63
ajax2_json.html Normal file
View File

@@ -0,0 +1,63 @@
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title></title>
</head>
<body>
<p> Ciao, Simone è gay?</p>
<p id="answer"></p>
<form id="form">
<input type ="text" name="nome" placeholder="Inserisci il nome" value="" />
<input type ="text" name="cognome" placeholder="Inserisci il cognome" value=""/>
<input type ="number" name="eta" min="10" max="120" placeholder="Inserisci eta" value="" />
</form>
<br>
<span id ="data"></span>
<span id ="debug"></span>
<script>
req= new XMLHttpRequest();
req.addEventListener("load",handlerload,false);
i = document.getElementsByTagName("input");
for (k=0;k< i.length;k++)
i[k].addEventListener("input",handler,false);
function handler(e) {
dati={};
form = (document.getElementById("form"));
fc = form.children;
for (i = 0; i < fc.length; i++){
if ((fc[i].tagName == "INPUT") && (fc[i].hasAttribute("name") ) ) {
dati[fc[i].getAttribute("name")] = fc[i].value;
}
}
req.open("POST","ajax2_json.php",true);
req.setRequestHeader('Content-Type', 'application/json');
req.send(JSON.stringify(dati));
}
function handlerload(e){
document.getElementById("data").innerHTML = req.responseText;
}
</script>
</body>
</html>

16
ajax2_json.php Normal file
View File

@@ -0,0 +1,16 @@
<?php
/**
* Created by xgiovio.
* User: Giovanni
* Date: 05/12/2014
* Time: 13:36
*/
$json = file_get_contents('php://input');
if ($json){
print_r(json_decode($json));
}else
echo "No data yet";
?>

28
dom1.html Normal file
View File

@@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title></title>
</head>
<body>
<div>
<p>ciao</p>
<p>ciao</p>
<p>ciao</p>
<p>ciao</p>
<p>ciao</p>
<p>ciao</p>
</div>
<script>
document.querySelectorAll("div > p:nth-child(2n+2) ")[1].style="color:green";
</script>
</body>
</html>