0
asp to php info

/t5/dreamweaver-discussions/asp-to-php-info/td-p/982938
Jan 22, 2008
Jan 22, 2008
Copy link to clipboard
Copied
ASP:
<%
if Request.QueryString("affid") <> "" then
set rsAffiliateClicks = Server.CreateObject("ADODB.Recordset")
rsAffiliateClicks.ActiveConnection = MM_cnConnection_STRING
rsAffiliateClicks.Source = "SELECT id, date, affid, referURL FROM affiliateClicks"
rsAffiliateClicks.CursorType = 0
rsAffiliateClicks.CursorLocation = 2
rsAffiliateClicks.LockType = 3
rsAffiliateClicks.Open()
rsAffiliateClicks_numRows = 0
rsAffiliateClicks.addnew
rsAffiliateClicks("date") = date()
rsAffiliateClicks("affid") = Request.QueryString("affid")
rsAffiliateClicks("referURL") = Request.ServerVariables("HTTP_REFERER")
rsAffiliateClicks.update
rsAffiliateClicks.close
end if
%>
PHP:?
How do I initiate the update and addition of a record in the database from within the recordset as I have done here in ASP.
<%
if Request.QueryString("affid") <> "" then
set rsAffiliateClicks = Server.CreateObject("ADODB.Recordset")
rsAffiliateClicks.ActiveConnection = MM_cnConnection_STRING
rsAffiliateClicks.Source = "SELECT id, date, affid, referURL FROM affiliateClicks"
rsAffiliateClicks.CursorType = 0
rsAffiliateClicks.CursorLocation = 2
rsAffiliateClicks.LockType = 3
rsAffiliateClicks.Open()
rsAffiliateClicks_numRows = 0
rsAffiliateClicks.addnew
rsAffiliateClicks("date") = date()
rsAffiliateClicks("affid") = Request.QueryString("affid")
rsAffiliateClicks("referURL") = Request.ServerVariables("HTTP_REFERER")
rsAffiliateClicks.update
rsAffiliateClicks.close
end if
%>
PHP:?
How do I initiate the update and addition of a record in the database from within the recordset as I have done here in ASP.
TOPICS
Server side applications
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

Guest
AUTHOR
/t5/dreamweaver-discussions/asp-to-php-info/m-p/982939#M168144
Jan 24, 2008
Jan 24, 2008
Copy link to clipboard
Copied
Is this not something you can do in PHP?
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
LEGEND
,
/t5/dreamweaver-discussions/asp-to-php-info/m-p/982940#M168145
Jan 25, 2008
Jan 25, 2008
Copy link to clipboard
Copied
"jsteinmann" <webforumsuser@macromedia.com> wrote in message
news:fn4a15$hp3$1@forums.macromedia.com...
> ASP:
>
> <%
> if Request.QueryString("affid") <> "" then
>
> set rsAffiliateClicks = Server.CreateObject("ADODB.Recordset")
> rsAffiliateClicks.ActiveConnection = MM_cnConnection_STRING
> rsAffiliateClicks.Source = "SELECT id, date, affid, referURL FROM
> affiliateClicks"
> rsAffiliateClicks.CursorType = 0
> rsAffiliateClicks.CursorLocation = 2
> rsAffiliateClicks.LockType = 3
> rsAffiliateClicks.Open()
> rsAffiliateClicks_numRows = 0
> rsAffiliateClicks.addnew
>
> rsAffiliateClicks("date") = date()
> rsAffiliateClicks("affid") = Request.QueryString("affid")
> rsAffiliateClicks("referURL") = Request.ServerVariables("HTTP_REFERER")
>
> rsAffiliateClicks.update
> rsAffiliateClicks.close
> end if
> %>
>
> PHP:?
> How do I initiate the update and addition of a record in the database from
> within the recordset as I have done here in ASP.
To use similar syntax in PHP you can use the ADOdb PHP Database abstraction
layer,
InterAKT (who made the ADDT) have developed the dreamweaver extension phAKT
that adds a new server-model PHP ADODB to dreamweaver and replicates the
standard dreamweaver ServerBehaviors up to Dreamweaver 8, however after the
merger with adobe the project was discontinued and not available for
download anymore. Since the project was released under the LGPL licence I've
setup a project on sourceforge with the aim of continuing distribution and
possibly development of the phaKT server model, to differentiate this
project from the original version we deceided to name it openphakt.
You can access the project website and source code repository from
http://openphakt.sourceforge.net ; to download the MXP look in the SVN
repository under the release folder
While the goal of continued distribution has been reached, nobody has
reported bugs/issues to the sourceforge project and development hasn't
started yet. If you have questions about the project I would be happy to
answer them.
Joris van Lier
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
LEGEND
,
/t5/dreamweaver-discussions/asp-to-php-info/m-p/982941#M168146
Jan 25, 2008
Jan 25, 2008
Copy link to clipboard
Copied
"jsteinmann" <webforumsuser@macromedia.com> wrote in
message
news:fnaf5b$fp0$1@forums.macromedia.com...
> Is this not something you can do in PHP?
The magic word for this type of database interaction is "ActiveRecord"
I've posted a small example at
http://www.dmxzone.nl/showDetail.asp?TypeId=25&NewsId=12415
news:fnaf5b$fp0$1@forums.macromedia.com...
> Is this not something you can do in PHP?
The magic word for this type of database interaction is "ActiveRecord"
I've posted a small example at
http://www.dmxzone.nl/showDetail.asp?TypeId=25&NewsId=12415
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

Guest
AUTHOR
/t5/dreamweaver-discussions/asp-to-php-info/m-p/982942#M168147
Jan 25, 2008
Jan 25, 2008
Copy link to clipboard
Copied
good luck with that.
i wonder what could be done in php as a work around, accomplishing the same thing but with mysql?
i wonder what could be done in php as a work around, accomplishing the same thing but with mysql?
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
LEGEND
,
LATEST
/t5/dreamweaver-discussions/asp-to-php-info/m-p/982943#M168149
Jan 26, 2008
Jan 26, 2008
Copy link to clipboard
Copied
"jsteinmann" <webforumsuser@macromedia.com> wrote in
message
news:fne6i0$qaf$1@forums.macromedia.com...
> good luck with that.
>
> i wonder what could be done in php as a work around, accomplishing the
> same thing but with mysql?
A lot can be done there are many activerecord implementations but none are
supported by dreamweaver afaik.
http://en.wikipedia.org/wiki/List_of_object-relational_mapping_software
There's a feature request for an object datasource serverbehavior which if
implemented could be used to provide UI support for ActiveRecord
implementations
http://sourceforge.net/tracker/index.php?func=detail&aid=1776864&group_id=201846&atid=979195
news:fne6i0$qaf$1@forums.macromedia.com...
> good luck with that.
>
> i wonder what could be done in php as a work around, accomplishing the
> same thing but with mysql?
A lot can be done there are many activerecord implementations but none are
supported by dreamweaver afaik.
http://en.wikipedia.org/wiki/List_of_object-relational_mapping_software
There's a feature request for an object datasource serverbehavior which if
implemented could be used to provide UI support for ActiveRecord
implementations
http://sourceforge.net/tracker/index.php?func=detail&aid=1776864&group_id=201846&atid=979195
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

