Is there a web site or tool that will convert a piece PHP code to C#?
something similar to
http://converter.telerik.com/
or
http://www.developerfusion.com/tools/convert/csharp-to-vb/
After frustration with installing custom designed skins for ZenCart, I was wondering which, if any, of the PHP shopping carts out there have a good templating system that makes it easy (or easier) to install custom designs?
Are there any robust and mature HTML parsers available for PHP? A quick skimming of PEAR didn't turn anything up (lots of classes for generating HTML, not so much for consuming), and Google taught me a lot of people have started and then abandoned a variety of parser projects.
Not interested in XML parsers (unless then can consume non-well formed HTML) or hacking it on my own with regular expressions.
Clarification of Intent: I'm not interested in filtering of HTML content, I'm interesting in extracting information from HTML documents.
How convert PHP value from windows-1257 to UTF-8? I tried many ways, but they was not successful. I have lttu?s and I wanna convert this to littus.
utf8_encode();
iconv_set_encoding("windows-1257", "UTF-8");
mb_convert_encoding()
Doesn't work. :(
Can anybody help me?
Hi,
I have a php login which sets 2 cookies once some one login. the problem is that if you login from : http://www.mydomain.com and you go to http://mydomain.com you will find your self not logged in, I think that's because the browser only send the cookies to the first syntax.
It's only one domain, the difference is the www. before the domain name, so how to set cookies to the whole domain whatever there is www. or not ?
Thanks
I'm interested in knowing if there is a pure object oriented database for PHP. Something similar to zodb for Python.
I'm not really looking for an object-relational mapper. So no active record clones...
Hi,
Not sure if this is a available as I am new to the MVC model. But does any one have a link or link's to a article or blogs about building a MVC based PHP web application without using a Framework ?
Thanks in advance.
Hi,
Does anyone of you ever heard about a PHP open source solution that would have these features:
Users login/registration (ideally connect via Facebook)
Upload photos
Rich backend administration with different roles and views on the users and their uploaded photos
Cheers,
Nicolas.
is it possible, that in php something, which was written as comment( like //comment...), makes some influence on the script? i remember, that once i use open source script, but when i delete all comments from it, it became non working. sorry for an abstract question. i haven't the code now, so i dont show it.
Hi all,
I have an object in PHP with some very odd property names. I just need to know how to access a property when it's name is "//www.w3.org/1999/02/22-rdf-syntax-ns#type".
I found something that suggested
$object->{'//www.w3.org/1999/02/22-rdf-syntax-ns#type'};
but that doesn't seem to work.
Thanks in advance
Rob
I was think of learning Perl cause I hear around town its good for system admin things. Would it be possible to use it to automatically install a php script? I need to install a custom script on a few different server and wanted to know how I could make something in Perl to do it (like move scripts over to directory and stuff)?
I am using config file which contains:
config.php
define('SYS_TITLE','My Application Title');
I load language local for gettext based on SESSION variable in another file included after the config file is loaded.
something like:
echo _(SYS_TITLE);
What is the best way to translate the SYS_TITLE without changing much of the code.
I'm very surprised I couldn't find this question here, which makes me very sure it is here and I just didn't see it. Regardless, I'll ask again.
How do I echo a forwardslash "/"?
echo <?php echo $_SERVER['HTTP_HOST'] ?> . '/directory/';
Thanks
-J
How do I use the sha512 function for PHP?
Can I replace all my md5 funtions with the sha512 function?
Do I have to download something if so what?
Can any one provide examples? Thanks!
Hi,
Does anyone know of a PHP open source which can generate forms to be deployed across your website. These forms will collect and aggregate the data with in on database. There should also be the functionality to search across the forms (to generate reports and newsletter mailing lists)
All the services I have found so far have been hosted solutions.
Thanks
Tom
I have PHP configured so that magic quotes are on and register globals are off.
I do my best to always call htmlentities() for anything I am outputing that is derived from user input.
I also occasionally seach my database for common things used in xss attached such as...
<script
What else should I be doing and how can I make sure that the things I am trying to do are always done.
Hi,
Rasmus Lerdorf (creator of php) advocates procedural style where as most successful way has turned out to be non-procedural. What is the benefit of procedural over non-procedural approach at last? Why does he advocate that?
Is there some way to detect if a string has been base64_encoded() in PHP?
We're converting some storage from plain text to base64 and part of it lives in a cookie that needs to be updated. I'd like to reset their cookie if the text has not yet been encoded, otherwise leave it alone.
Hi
Could you show me a Proof-Of-Concept for all of these: XSS, CSRF, SQL injection with both the source code and the attack steps for each?
Other attack vectors are welcome. The most complete answer gets accepted.
The configuration is a fairly standard one, as of PHP 5.3.2, core settings:
allow_call_time_pass_reference => Off => Off
allow_url_fopen => On => On
allow_url_include => Off => Off
always_populate_raw_post_data => Off => Off
arg_separator.input => & => &
arg_separator.output => & => &
asp_tags => Off => Off
auto_append_file => no value => no value
auto_globals_jit => On => On
auto_prepend_file => no value => no value
browscap => no value => no value
default_charset => no value => no value
default_mimetype => text/html => text/html
define_syslog_variables => Off => Off
disable_classes => no value => no value
disable_functions => no value => no value
display_errors => STDOUT => STDOUT
display_startup_errors => On => On
doc_root => no value => no value
docref_ext => no value => no value
docref_root => no value => no value
enable_dl => Off => Off
error_append_string => no value => no value
error_log => syslog => syslog
error_prepend_string => no value => no value
error_reporting => 32767 => 32767
exit_on_timeout => Off => Off
expose_php => On => On
extension_dir => /usr/lib/php/modules/ => /usr/lib/php/modules/
file_uploads => On => On
html_errors => Off => Off
ignore_repeated_errors => Off => Off
ignore_repeated_source => Off => Off
ignore_user_abort => Off => Off
implicit_flush => On => On
include_path => .:/usr/share/pear => .:/usr/share/pear
log_errors => On => On
log_errors_max_len => 1024 => 1024
magic_quotes_gpc => Off => Off
magic_quotes_runtime => Off => Off
magic_quotes_sybase => Off => Off
mail.add_x_header => On => On
mail.force_extra_parameters => no value => no value
mail.log => no value => no value
max_execution_time => 0 => 0
max_file_uploads => 20 => 20
max_input_nesting_level => 64 => 64
max_input_time => -1 => -1
memory_limit => 128M => 128M
open_basedir => no value => no value
output_buffering => 0 => 0
output_handler => no value => no value
post_max_size => 8M => 8M
precision => 14 => 14
realpath_cache_size => 16K => 16K
realpath_cache_ttl => 120 => 120
register_argc_argv => On => On
register_globals => Off => Off
register_long_arrays => Off => Off
report_memleaks => On => On
report_zend_debug => Off => Off
request_order => GP => GP
safe_mode => Off => Off
safe_mode_exec_dir => no value => no value
safe_mode_gid => Off => Off
safe_mode_include_dir => no value => no value
sendmail_from => no value => no value
sendmail_path => /usr/sbin/sendmail -t -i => /usr/sbin/sendmail -t -i
serialize_precision => 100 => 100
short_open_tag => Off => Off
SMTP => localhost => localhost
smtp_port => 25 => 25
sql.safe_mode => Off => Off
track_errors => Off => Off
unserialize_callback_func => no value => no value
upload_max_filesize => 2M => 2M
upload_tmp_dir => no value => no value
user_dir => no value => no value
user_ini.cache_ttl => 300 => 300
user_ini.filename => .user.ini => .user.ini
variables_order => GPCS => GPCS
xmlrpc_error_number => 0 => 0
xmlrpc_errors => Off => Off
y2k_compliance => On => On
zend.enable_gc => On => On
I am trying to install a copy of PHP 5 to my home directory on the school computer. The problem is that whenever I try, it complains that my copy of libxml2 is too outdated to work.
Is there any way I can install this without upgrading libxml2, since I don't have permission to upgrade.
Any suggestions?
I've wrote a PHP script to export a Foxpro database to other formats by using ADODB (http://phplens.com/lens/adodb) library to access Foxpro OLE DB provider.
Everything worked fine except the date fields are mangled and become like these:
11/17-/2-00
3/4/-20-08
By comparing to actual data I can guess that it is probably in the format of MM/DD/YYYY or m/d/YYYY.
How can I properly export the date field?
Hi, i need to convert a Utf-16BE in ISO-8859-1 in PHP (i'm not an expert in encoding so i don't know if Utf-16 and Utf-16BE are the same thing). I've read somewhere to use the mb_convert_encoding function but i haven't that function because i don't have the multibyte extension installed. So do you know an alternative method to do this?
I want to be able to detect (using regular expressions) if a string contains hebrew characters both utf8 and iso8859-8 in the php programming language. thanks!