473,385 Members | 1,764 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

calling js into php

chelvan
90
hi
all


i've a js function. i'm trying to call that on php script. before that i just check a condition when the conditions become true, i called that js. but that js function not depended on that condition, it always worked. why?


chel-1
Sep 23 '08 #1
4 1082
Markus
6,050 Expert 4TB
I'm sorry but I don't understand your question too clearly.

You're asking me (and others) about something we can't see and, therefore, can't possibly begin to know the problem. Che1, you've been here long enough to know that for us to help you, you need to help us. It's a simple as that.
Sep 23 '08 #2
chelvan
90
I'm sorry but I don't understand your question too clearly.

You're asking me (and others) about something we can't see and, therefore, can't possibly begin to know the problem. Che1, you've been here long enough to know that for us to help you, you need to help us. It's a simple as that.
hi
here my codes

Expand|Select|Wrap|Line Numbers
  1. <script type='text/javascript'><!--
  2. function loadSite(){
  3. window.location ='home.php?$u_n';
  4. }
  5. --></script>
  6.  


then my php here i check
Expand|Select|Wrap|Line Numbers
  1. if($agree =!isset($_POST['t19']) ){
  2. //inserting query
  3. }
  4. else{
  5. echo"<script type='text/javascript'>
  6.                                                                                         <!--
  7.                                                                                         loadSite();
  8.  
  9.                                                                                         -->
  10.                                                                                         </script>";
  11. }
  12.  
on the above php's else block worked always. that not dependent on the condition

thanks

chel-1
Sep 24 '08 #3
Markus
6,050 Expert 4TB
hi
here my codes

Expand|Select|Wrap|Line Numbers
  1. <script type='text/javascript'><!--
  2. function loadSite(){
  3. window.location ='home.php?$u_n';
  4. }
  5. --></script>
  6.  


then my php here i check
Expand|Select|Wrap|Line Numbers
  1. if($agree =!isset($_POST['t19']) ){
  2. //inserting query
  3. }
  4. else{
  5. echo"<script type='text/javascript'>
  6.                                                                                         <!--
  7.                                                                                         loadSite();
  8.  
  9.                                                                                         -->
  10.                                                                                         </script>";
  11. }
  12.  
on the above php's else block worked always. that not dependent on the condition

thanks

chel-1
Is $agree a boolean value? Because that's what
Expand|Select|Wrap|Line Numbers
  1. !isset($_POST['t19'])
  2.  
will return.
Sep 24 '08 #4
chelvan
90
Is $agree a boolean value? Because that's what
Expand|Select|Wrap|Line Numbers
  1. !isset($_POST['t19'])
  2.  
will return.
ya thats checked combobox is checked or not.returns boolean. if checked that will insert something to database. if not i call the javascript. but the javascript work on both condition.


chel-1
Sep 25 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Muthu | last post by:
I've read calling conventions to be the order(reverse or forward) in which the parameters are being read & understood by compilers. For ex. the following function. int Add(int p1, int p2, int...
5
by: Nick Flandry | last post by:
I'm running into an Invalid Cast Exception on an ASP.NET application that runs fine in my development environment (Win2K server running IIS 5) and a test environment (also Win2K server running IIS...
7
by: =?Utf-8?B?UVNJRGV2ZWxvcGVy?= | last post by:
I have a C# logging assembly with a static constructor and methods that is called from another C# Assembly that is used as a COM interface for a VB6 Application. Ideally I need to build a file...
10
by: sulekhasweety | last post by:
Hi, the following is the definition for calling convention ,which I have seen in a text book, can anyone give a more detailed explanation in terms of ANSI - C "the requirements that a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.