Welcome Guest! To enable all features please Login. New Registrations are disabled.



Go to last post Go to first unread
#1 Posted : Friday, September 4, 2015 2:17:27 PM(UTC)

Rank: Administration


Groups: Moderators, Administration, Member
Joined: 10/8/2008(UTC)
Posts: 44

What it does:

It uses a control to send website-visitors to pageA or pageB per session with a 302 redirect (so the original page will stay in the google-cache, and the test page will not be entered into the google-index. You have to setup a SIENN-table with some fields, and put a control in the original page.
This control will send you to pageA or B depending on it's session. Put the control in a text/view/form/whatever with a parameter (with the value of the identifier).
EG: if the opencontrol is number 73 and you use identifier 1:

In your testpages (pageA and pageB) put noindex and nofollow metatag:
<meta name="robots" content="noindex, nofollow">

After your testing (after a month or so) you can put the code of the new page in the original page and delete the control and the metatags.

The SIENN-table:

Tablename: abtest
Field: identifier (integer) UNIQUE, required, show at overview
Field: toggle (bit)
Field: urla (textX 500), required, show at overview
Field: urlb (textX 500), required, show at overview

The code of the control:

Dim Identifier as integer = Par(0)
'Dim Cid As String = SApp.SSetup.SiennClientCid 'ML engine 
Dim Cid as string = pbw.get_Cid_currentdomain() 'CMS4 engine
Dim Prefix As String = Cid & "U_"
Dim ABsessionstring as string = "ABTEST" & Identifier
Dim ABSession as string = Session(ABsessionstring)
Dim Url as string = ""
If not string.IsNullOrEmpty(ABSession) Then
  Url = ABSession
    Using con As New SqlConnection(Constring)
            Dim queryStr As String = String.Format(" update [{0}abtest] Set toggle = 0 where Toggle IS NULL " &
                                        " SELECT  " &
                                        "     CASE WHEN [toggle] = 1 " &
                                        "       Then [urla] " &
                                        "     else  [urlb] " &
                                        "   END  as url" &
                                        " FROM [dbo].[{0}abtest] " &
                                        " where identifier =@ident " &
                                        " update [{0}abtest] " &
                                        " set toggle = [toggle] ^ 1 " &
                                        " where identifier =@ident ", Prefix)
            Dim com As New SqlCommand(queryStr, con)
            com.Parameters.AddWithValue("@ident", Identifier)
            Dim Reader As SqlDataReader = Com.ExecuteReader()
            While Reader.Read()
                Url = Microsoft.VisualBasic.Iif(Not Microsoft.VisualBasic.IsDBNull(reader("url")), reader("url"), "") 
            End While
        Catch ex As Exception
        End Try
    End Using
    Session(ABsessionstring) = Url
End If

If not string.IsNullOrEmpty(Url) Then
End If

Edited by user Wednesday, September 9, 2015 10:48:24 AM(UTC)  | Reason: Not specified

Wanna join the discussion?! Login to your Sienn Forum forum account. New Registrations are disabled.

Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.