< Home

url (URL template view)

Function

The url command configures a redirect URL or pushed URL.

The undo url command cancels a redirect URL or pushed URL.

By default, no redirect URL or pushed URL is configured.

Format

url [ push-only | redirect-only ] url-string [ ssid ssid ]

undo url [ push-only | redirect-only ] [ ssid ssid ]

Only the S5730-HI, S5731-H, S5731S-H, S6730-H, S6730S-H, S5732-H, S6720-HI, and S5720-HI support the ssid ssid parameter.

Parameters

Parameter

Description

Value

url-string

Specifies a redirect URL or pushed URL.

The value is a string of 1 to 247 case-sensitive characters without spaces. If the string is enclosed in double quotation marks (" "), the string can contain spaces.

push-only

Specifies the URL only as a pushed URL.

-

redirect-only

Specifies the URL only as a redirect URL.

-

ssid ssid

Specifies the SSID that users associate with.

This parameter is valid only for wireless access users. The SSID that users associate with must be the same as that configured on the device; otherwise, the device cannot push URLs to users.

The SSID must already exist.

Views

URL template view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

After a URL template is created using the url-template name command, you can run this command to configure a redirect URL or pushed URL. The difference between a redirect URL and a pushed URL is as follows:
  • Redirect URL: When a user without network access permission attempts to access the network, the Portal authentication device redirects the user to the redirect URL for authentication.
  • Pushed URL: After an authenticated user accesses the network through web for the first time, the access device pushes the web page corresponding to the URL to the user. The web access request from the user is redirected to the specified URL, and then the user is allowed to access network resources.

When you configure a URL on the device, question marks (?) are not supported. If a URL contains a question mark (?), you can run the parameter start-mark # command in the URL template view to replace the question mark (?) with a number sign (#).

Precautions

If the push-only and redirect-only parameters are not specified, the configured URL is used as both a redirect URL and a pushed URL. You can configure a pushed URL using the force-push command, or use the url-template command to bind a URL template to the Portal server template to configure a redirect URL.

Example

# Set the redirect URL to http://10.1.1.1.

<HUAWEI> system-view
[HUAWEI] url-template name huawei
[HUAWEI-url-template-huawei] url http://10.1.1.1
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >