Is there any way I can display a links location absolutely when I only reference it relatively.
I.e. A file is relatively referenced like...
<a href='../../files/uploaded_file.jpg'>Your Uploaded File</a>
But I would also like to display some text saying...
You can link to your file via www.example.com/files/uploaded_file.jpg
The c...
I have to protect my code? which is the best method for protecting our codes? any body can help me?
...
I store user images in "images" forlder and the full path is something like this:
http://example.com/images/imagename.jpg
When I try to get the image path like this:
$path = 'images/imagename.jpg';
it works fine on home page, but since I have different permalink structure it doesn't work on other pages. It becames something like...
Hello,
I am migrating my Facebook canvas application to using the new PHP SDK. However, I am having a problem getting the JavaScript SDK to work too.
I'm wanting to take advantage of methods such as stream.publish in the JavaScript SDK. Unfortunately I've not been able to get anything to work thus far. I have the following in the heade...
Usually when building sites I add something like this
var config = {
basePath: '<?php echo BASE_PATH; ?>'
}
Simply so with my static JavaScript files I can do AJAX requests like
var request = config.basePath + 'ajax/get-something';
Does WordPress have a similar variable available to its JavaScript files by default, assuming I a...
I want to add an own shipping method during checkout_shipping.php. Something like a dropdown list, from that the customer will select his shipping method and enter his own account no in a textbox. How should I implement this?
...
By "common script startup sequence", what I mean is that in the majority of pages on my site, the first order of business is to consult 3 specific files (via include()), which centrally define constants, certain functions used in many scripts, and a class or two, as well as providing the database credentials. I don't know if there's a mo...
I have this array,
Array
(
[campaign_title] => adasdasdasddsad
[campaign_keyword] => asdsadasdasdasdasd
[introduction] => asdasdasdasdasdasdsa
[campaign_headline] => Array
(
[0] => asdasdasdasdasdasdad
)
[article] => Array
(
[0] => asdasdasdasdasdasdasdasdsadas
...
Hi,
Soon I'll be working on catalog(php+mysql) that will have multilang content support. And now I'm considering the best approach to design the database structure. At the moment I see 3 ways for multilang handling:
1) Having separate tables for each language specific data, i.e. schematicly it'll look like this:
There will be one tab...
preg_match_all('|(.*?)|', $read, $foo, PREG_SET_ORDER);
print_r($foo);
output as just
Array ( )
Where i made mistake
See guys ,
Actually i want to grab the exact details from this URL
i want to pick this details from this URL
08:35 9W5048 TORONTO EXPECTED 1358 Terminal three
So i tried this snippet , but...
Hi,
for our project we need to set several PHP values depending on the environment (development/production), most notably session save path and some tracing and profiling settings.
We do not want to set them in the PHP script because due to some horrible legacy code which would require a lot of changes and we don't want to have to chang...
i was trying to access this php array with no luck, i want to access the [icon] => icon.png
Array ( [total] => 2
[total_grouped] => 2
[notifys] => Array ( [0] => Array ( [notifytype_id] => 12
[grouped] => 930
[icon] => icon.png
[n_url] => wall_action.php?id=930
[desc] => 690706096
...
i have this code
var myChart = new FusionCharts("../themes/clean/charts/hbullet.swf", "myChartId", "400", "75", "0", "0");
myChart.setDataXML("<chart lowerLimit='0' upperLimit='100' caption='Revenue' subcaption='US $ (1,000s)' numberPrefix='$' numberSuffix='K' showValue='1'><colorRange><color minValue='0' maxValue='50' color='A6A...
Can somebody explain to me when it's a good practice to use models in CI?
An article in wikipedia was referring to CI models as "entirely optional and are rarely needed" is that true in any way?thanks in advance!
...
I'm new to sessions and PHP. I know how to set the expiration of a cookie. I wanted to know how is something similar done for a session.
...
Hi guys I'm setting up mywebapplication to give unique urls for users such as uniquename.mysite.com, anotheuniqname.mysite.com etc.
I want to be able to in a php script grab the subdomain part of the url. Would be nice if I can get it as a GET variable - I think it can be done with htaccess. Any ideas?
...
Hello there!
I have been working with PHP for a couple of years now but I don't consider myself any more than a moderate programmer.
While creating some websites (varying from presentation websites to some simple CMS'es), I have taken 2 approaches which I will discuss below. My question is simple: which one is better in terms of custom...
I have to give the Html code of my order form to third parties. Once they register and payed they can copy and paste the html code from my site to their own site. but the date will be saved in my site with the reference of the reseller. How can I implement this kind of a section in my website. any body can help me. I am using php5 and my...
I have a PHP process running as a result of a JavaScript AJAX request, which is potentially running for some time and will produce data from time to time. From a usability perspective, I'd like to be able to return data to the JavaScript as soon as it's produced, but this appears not to be possible.
My workaround is to write it to an SQ...
I have MySQL Table with an Order table in a DB this table has an auto-incremental id. Up-till now we have general numeric Order-ID likewise 1,2,3,4,5... From now onwards I have to append the series A20 to my id like A20103, A20104, A20105 and so on and when the last three digits reaches 999 the series appended should get changed to A2100...