Embodiment
Mobile terminal, which is applied, often has some information needs in five application page displaying in APP, for example, such as Fig. 1 example, figure
1 illustrates in the prepaid mobile phone recharging page in an application, it is shown that an advertising message " is congratulated to obtain to stand at random and subtracts red packet, fill
Telephone expenses can at most deduct 500 yuan, each user ... .. ", when user just can be appreciated that the advertising message when the page is supplemented with money.At it
In his example, the industry such as display " transferred account service temporary close today " in the bank card transfer page of an application can also be
Business information.The present embodiment is not limited in the type of the information shown in the application of mobile terminal, and various information can be in applications pages
Shown in face, these information can be referred to as " announcement information " by embodiments herein, i.e., by information application show with
User is notified to know these information.
When announcement information is shown in the application, if announcement information is included into the tip position in five application page, and
The content of pages that the information can be caused to cover is lived into tip position is shown, it would be possible to have influence on the regular traffic function of application.Such as, if
On the page being currently displaying in mobile terminal, there is an input frame at the tip position of the page, user can use the input
Frame inputs information to trigger corresponding business function, and if announcement information is directly displayed at into the tip position, and cover
The content of pages of tip position, then user cannot use the input frame, so as to have influence on the normal presentation of the page, also influences
The normal function of application is used.
In order to solve the above problems, embodiments herein provides a kind of information displaying method, and this method can be applied
In mobile terminal application, for example, the operating system of the mobile terminal can be iOS or Android, etc..As shown in Fig. 2 the information
The processing of methods of exhibiting can include:
In step 201, the page location for current page mobile terminal applied is moved down.
For example, in the method for this example, user by the mobile phone of oneself using mobile terminal when being applied, on mobile phone screen just
Some content of pages can be included in the five application page of display is current page, current page, such as, similar in Fig. 1
The shown content of pages for supplementing the page with money.Can be opened up together with the content of pages of current page for the announcement information of displaying
The information shown.Such as, in the example in fig 1, " to congratulate to obtain random vertical in the prepaid mobile phone recharging page advertisement demonstration information of application
Subtract red packet, charge filling can at most deduct 500 yuan, each user ... .. ", then the advertising message is to be properly termed as announcement information,
Current page is the prepaid mobile phone recharging page, and supplementing content and advertising message in the page with money can show on mobile phone screen.
, can be by the page of current page in order to avoid announcement information covers the content of pages of current page in this step
Face position is moved down.Such as, by Fig. 1 it can also be seen that the content such as " charge filling ", " filling flow " in the prepaid mobile phone recharging page,
It should be shown in below navigation bar, exactly be moved downwardly certain distance, be that position has been vacated in the display of advertising message.
In step 202., vacated mobile terminal viewing area is moved down in current page, announcement information is shown.
As above the example being previously mentioned in step 201, can move down current page certain distance, such current page
Content of pages moved downwardly together also with the page, provide advertising message in region, such as Fig. 1 for the displaying of announcement information
The page is shown in move down in vacated region, would not cover page content during the displaying of such advertising message, it is to avoid influence
Normal page function.
The information displaying method that the present embodiment is provided, vacated aobvious is moved down by the way that announcement information is illustrated in into current page
Show region so that the displaying of announcement information will not cover page content, it is possible to so that information will not when five application page is shown
Influence the normal function of application.
In one example, so that announcement information is ad content as an example, such as Fig. 1 examples supplement teaser with money, can be with
The information displaying side of the application is performed by advertisement SDK (Software Development Kit, SDK)
Method, to show ad content in the application.Wherein, advertisement SDK can apply in a certain mobile terminal application, also, mobile terminal
The service end of application can be shown ad content in the application by advertisement SDK to advertisement SDK advertisement contents.
Fig. 3 illustrates a kind of flow of the information displaying method performed by advertisement SDK, can include:
In step 301, detect default displaying trigger condition to reach, the displaying trigger condition, which is used for expression, to be opened
The displaying for beginning to perform ad content is handled.
For example, the displaying trigger condition described in this example, can include:Current page refreshes display, such as, user is looking into
See after other mobile terminal applications, be returned to the mobile terminal application of this example;Or, the page of mobile terminal application is added again
Carry;Again such as, it can also be that advertisement SDK have received the announcement information of service end transmission, wherein, when advertisement SDK is in execution pair
During the displaying of some ad content, if receiving the new announcement information of service end transmission again, advertisement SDK also can be true
It is set to displaying trigger condition to reach.Displaying trigger condition in actual use is not limited to the above-mentioned several situations enumerated.
In step 302, the page iden-tity of current page is obtained.
Wherein, the page iden-tity of this step, for example, can include:Page Name (View Controller Name), page
Application identities (app ID), page address (url of the page) belonging to face etc. are capable of the information of unique mark some five application page.
In step 303, according to page iden-tity, announcement information corresponding with page iden-tity, the page are judged whether
Face, which identifies corresponding announcement information, to be used to be shown in the corresponding current page of page iden-tity.
For example, the service end of application can indicate issued ad content when ad content is issued into advertisement SDK
Need which page in application is shown, i.e. the corresponding relation of five application page and ad content, wherein, in corresponding relation
Five application page can be represented with page iden-tity.When advertisement SDK, which detects displaying trigger condition, to be reached, current page can be obtained
Page iden-tity, and according to page iden-tity and above-mentioned corresponding relation, checked whether service end issue the need for page in this prior
The ad content of face displaying.
In this step, if it is judged that being yes, advertisement SDK will perform step 304, get corresponding with page iden-tity
Ad content, and the ad content is shown in the application.
But in another example, it is also possible to situation about existing is that advertisement SDK has found current page exhibition not in need
The ad content shown, i.e. judged result are no, that is to say, that current page need not show advertisement;So, advertisement SDK can be with
Step 305 is performed, judges whether current page has illustrated advertisement, the shown advertisement can be last service end
Indicate what is shown in the page.If there is shown advertisement, advertisement SDK can be removed the advertisement that this has shown that,
So that current page performs step 306 without exhibiting advertising content.In displaying advertisement performed by specific above-mentioned advertisement SDK
The flow held and remove ad content will be described in subsequent embodiment, and step 307 wherein is also in subsequent descriptions.
Information displaying method in the example, be not from five application page itself to service end ask announcement information, but by
Advertisement SDK (can be certainly, other SDK in other examples) receives the announcement information of service end, and is responsible for opening up in the application
Show the information, which page that this mode can freely be customized in application by service end shows which announcement information, flexibility
Preferably, also, by SDK the displaying of ad content is performed, the RPC request resources of the page itself are saved;In addition, by announcement information
It is illustrated in current page and moves down vacated display location, is not also interfering with the normal presentation and page function of content of pages just
Often use.
In following example, so that mobile terminal operating system is iOS as an example, describe how advertisement SDK is performed in application respectively
Middle displaying ad content and removal ad content.
In one example, advertisement SDK can be by the upper strata hidden page of the currently displayed page of ad content.For example,
Assuming that current page is UIView, its upper page can be UIViewControllerWrapperView, and the page is individual hidden
The page is hidden, user can not perceive.The present embodiment can take that " current page is moved down, and by advertisement when showing ad content
Hold be illustrated in the hidden page of upper strata " mode, and this example can by exhibiting advertising content the page tip position.
Fig. 4 illustrates the displaying flow of ad content:
In step 401, determine ad content in the display location of upper strata hidden page.
For example, can according to upper strata hidden page UIViewControllerWrapperView page layout feature, by
Advertisement SDK determines display location of the ad content when upper strata hidden page is shown, the display location can use origin Y tables
Show.In one example, current page will be moved down, then one can be vacated above the viewing area of mobile terminal
Divide the region due to moving down offer, and ad content can be indicated in the viewing area that this moves down offer, can be set accordingly
It is scheduled on the described position for moving down the corresponding upper page in the region vacated, presenting advertising content.
In step 402, according to the display of ad content height and the display location, determine that ad content is hidden on upper strata
Hide the initial position of the page.
The ad content of this step in displaying is shown in animation form, such as, and ad content is before animation movement
There is a position, be properly termed as moving front position, and have a position after animation movement, be properly termed as position after movement.
The display location determined in step 401, can be as position after movement, and the initial position in this step is to be properly termed as moving
Dynamic front position.The difference of position can be the display height of ad content behind mobile front position and movement, and the display is highly held
The height of the viewing area of announcement information is carried, than the height of the moulding where advertising message as illustrated in figure 1.If advertisement
The display height of content is height, then mobile front position can be origin Y-height.Wherein, described in this example
Position can be object top edge apart from mobile terminal screen top distance (for example, the ad content shown in Fig. 1 be
One rectangle frame shows, the top edge of the rectangle frame is " position " apart from the distance of mobile phone screen tip edge).
In step 403, initial position when current page does not have ad content is determined.
For example, the initial position of the page is position when entering the page for the first time, advertisement SDK can be in internal memory with key-
The initial position of value mode memory page.The record of the page initial position, can be used for the page in page exception
Original state is returned to, to prevent the page from constantly moving down.Wherein, in the memory page initial position in the way of key-value,
Key representation pages are identified, and value can be page initial position, and the key needs to ensure some page of unique mark, for example,
Key=viewControllerName.In some specialized pages, Page Name and the title common ID of its parent page can be used
The uniqueness of the page, for example, key=viewControllerName+parentViewControllerName, such case
When the page parentViewControllerName be not usually navigationController.
In this step, advertisement SDK can obtain the page initial position of the current page of storage in internal memory, and the position can
Position before being moved as current page animation, is represented with origin Y2.
In step 404, according to the display of the page initial position of current page and ad content height, current page is determined
Position after the movement of face.
For example, according to the display height height of ad content, the position after current page UIView animations can be set
It is set to origin Y2+height.
In step 405, according to position after mobile front position and movement, the announcement information and current page are moved respectively
Face.
For example, can according to the announcement information determined in step 401 and 402 in the mobile front position of upper strata hidden page and
Position after movement, is set ad content to be shown in upper strata hidden page in the form of animation, is moved to by origin Y-height
origin Y.And current page is also moved down in animation form, origin Y2+height, class are moved to by origin Y2
The content of pages for being similar to current page has moved down height, accordingly, and ad content occupies the space of the height on upper strata
Hidden page is shown.
Effect after movement may refer to Fig. 5 example, as shown in figure 5, in the application interface of prepaid mobile phone recharging, " filling words
Take, fill flow " this line moved down certain distance height, and " congratulating to obtain and random vertical subtracts red packet ... " can be with for ad content
It is that the position for being moved to page top from top to bottom with the effect of animation is shown.In addition, in the ad content by similar to
During the animation of the marquee effect of word, the animation effect can be shown when showing ad content.
The present embodiment is realized in the form of animation, moves down current page certain distance, and in animation form by advertisement
The upper page relevant position that appearance is moved to current page is shown that the content of pages for not interfering with current page is shown, again
It can be very good to play the function of notice.
Wherein, advertisement SDK, can also be according to the page initial bit prestored before above-mentioned advertising display flow is carried out
Put, the current page is subjected to position initialization, prevents from previously being moved through causing page layout incorrect;Advertisement SDK can
To carry out position initialization in any detect when current page is laid out entanglement.In addition, during the displaying, by advertisement SDK
It is responsible for creating the ad content UI for needing to show and the mobile front and back position of advertisement and the page is calculated by advertisement SDK, and carries out phase
The animation movement answered, these process five application pages can be not involved in.If there is picture in ad content, it can wait under picture
The displaying process of advertisement is performed after carrying successfully again.
It should also be noted that, in the example of above-mentioned advertising display, ad content to be placed on to the upper strata of current page
Hidden page UIViewControllerWrapperView, is because by the current page UIView where Application Service Function
Position move down after, if ad content is placed on UIView, the position of ad content will be less than 0, ad content
On click event just all without there is response, such as, and user see wants after the ad content click on the ad content understand or make
With details, the ad content is clicked on, but does not have response, influence is normally used.With reference to shown in Fig. 6 left side, currently
The page is the viewing area in the rectangle frame below navigation bar, if the rectangular area to be moved down to the display height of ad content,
Ad content is included to move down vacated region, then click event on ad content is just all without there is response.
Or, in another example, ad content still can also be put into UIView and shown, it is empty to move down institute in correspondence
The current page of the mobile terminal viewing area gone out, shows the announcement information, and the mobile terminal viewing area is in current page
In page location be more than zero, i.e. UIView page initial position and need to be located at outside the screen of mobile terminal, and page initial position
Distance outside the screen of mobile terminal is not less than height, and so top advertisement can be put on UIView, and click event also has.
That is current page UIView is moved down after the display height of ad content, and the whole height of its current page is still covered with display screen
Curtain, can so ensure the response of click event.From the point of view of Fig. 6, current page is still rectangular area, simply the rectangle
The region in left side is compared in region, and its top is more top, even if moving down after certain distance, and the region is still occupied below full navigation bar
Region, click event can be responded.
Fig. 7 illustrates the flow of the removal ad content of advertisement SDK execution, for the removal of ad content, can be in clothes
Business end does not push the newest displaying advertisement of the page, and current page exist before shown advertisement when, by this
Shown advertisement is removed;Or, service end has the newest displaying advertisement of the page, and SDK has found the advertisement and current page
When shown advertisement is differed, the advertisement originally shown is removed.In following removal flow, with Fig. 4 flows
Identical step will be briefly described, and the animation moving process that advertisement is removed is opposite with the animation moving process of advertising display
's.
In step 701, determine ad content in the display location of upper strata hidden page.
In this step, advertisement SDK can determine display location origin of the ad content when upper strata hidden page is shown
Y.The position is the position before ad content is removed.
In a step 702, according to the display of ad content height and the display location, determine that ad content is hidden on upper strata
Hide the position after the movement of the page.
For example, the position after the ad content in this step is removed is origin Y-height.
In step 703, initial position when current page does not have ad content is determined.
For example, advertisement SDK can obtain the page initial position of the current page of storage in internal memory, the position can be
After ad content removal, original position that current page is returned to is represented with origin Y2.In the present example, in advertisement
Hold animation movement when being removed, accordingly, position that current page will be also returned to before exhibiting advertising content (in order to
Adapt to have been carried out moving down before the displaying of ad content, current page)
In step 704, according to the display of the page initial position of current page and ad content height, current page is determined
Position before the movement of face.
For example, according to the display height height of ad content, the position before current page UIView animations can be set
Origin Y2+height are set to, this is that ad content does not have started the current page position before removing, and current page can be from
The position origin Y2 that position origin Y2+height are moved in step 603.
In step 705, according to position after mobile front position and movement, the announcement information and current page are moved respectively
Face.
For example, ad content by origin Y can be moved to origin Y-height, and by current page also with dynamic
Picture form is moved up, and origin Y2 are moved to by origin Y2+height, and disappearance is moved up similar to ad content,
And the content of pages of current page moves up height, page initial position is returned to.Mobile process is equivalent to Fig. 5 example mistakes
The reverse procedure of journey.
In addition, when the page is returned, in order to allow top advertisement to follow the page to slide together, we monitor
The viewWillDisappear notice notice of disappearance (detect current page), has been found that there is top advertisement, this when
Time need not have click effect, can remove ad content from UIViewControllerWrapperView, and add
It is added on UIView, keeps visual position constant, held stationary transition.
In the above example, be with announcement information such as ad content is placed into current page UIView upper strata page
Exemplified by the UIViewControllerWrapperView of face, it is not limited thereto in actual implementation, such as, will can also notifies to believe
Breath is put into navigation bar position, for example, top bulletin is put into below UINavigationBar, with UINavigationBar bondings
Together, such ad content just can be in navigation bar position display.The display location of announcement information in this example, Ke Yiyou
A variety of positions, such as, can be navigation bar position, or or current page but current page page initial bit
Outside setting in mobile terminal screen, or, the upper strata hidden page of the currently displayed page is can also be, etc..No matter which kind of position,
It is required for, when showing announcement information, the content of pages that current page is shown not being override.
In order to realize above-mentioned method, the embodiment of the present application additionally provides a kind of device for displaying information, as shown in figure 8, should
Device can include:Page movement module 81 and displaying processing module 82.
Page movement module 81, for the page location of the current page to be moved down;
Processing module 82 is shown, for moving down vacated mobile terminal viewing area, announcement information is shown.
In one example, the upper strata hidden page of the currently displayed page of the announcement information.
In one example, processing module 82 is shown, the upper strata for being additionally operable to be located at current page when the display location is hidden
When hiding the page, if detecting the notice of current page disappearance, the announcement information is moved on into institute by the upper strata hidden page
State current page.
In one example, referring to Fig. 9, the device can also include:Data obtaining module 83, for reach it is default
When showing trigger condition, the page iden-tity of the current page is obtained;According to the page iden-tity, obtain and the page iden-tity
The corresponding announcement information.
In one example, the displaying trigger condition, including:Current page refreshes display, or, receive service end
The announcement information sent.
If the function of the device for displaying information of the embodiment of the present application is realized using in the form of SFU software functional unit and as solely
Vertical production marketing in use, can be stored in a computer read/write memory medium.Understood based on such, this Shen
The part or the part of the technical scheme that technical scheme please substantially contributes to prior art in other words can be with soft
The form of part product is embodied, and the computer software product is stored in a storage medium, including some instructions are to make
Obtain all or part of step that an equipment performs each embodiment methods described of the invention.And foregoing storage medium includes:U
Disk, mobile hard disk, read-only storage (ROM, Read-Only Memory), random access memory (RAM, Random Access
Memory), magnetic disc or CD etc. are various can be with the medium of store program codes.
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the invention, all essences in the present invention
God is with principle, and any modification, equivalent substitution and improvements done etc. should be included within the scope of protection of the invention.